//\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\
// UserRTX.NET satellite library | Author: Sergei Y.Kitáev
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
using System;

#if !WASM
namespace user_rtx { using u = user_rtx;
#else
namespace user_rtx.wasm { using u = user_rtx.wasm;
#endif

/// <summary>
/// Type argument checking errors (exception creation)
/// </summary>
public static partial class type_argcheck_errors {
//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

public static ArgumentException TYPE_IS_NOT( Type comparandType, string paramName ) =>
   new ArgumentException(
      $"Type is not “{comparandType}” type.",
      paramName );

public static ArgumentException VALUE_IS_NOT_OF( Type type, string paramName ) =>
   new ArgumentException(
      $"Value is not of “{type}” type.",
      paramName );

public static ArgumentException TYPE_IS_NOT_REFERENCE_TYPE( Type type, string paramName ) =>
   new ArgumentException(
      $"Type “{type}” is not reference type.",
      paramName );

public static ArgumentException TYPE_IS_NOT_VALUE_TYPE( Type type, string paramName ) =>
   new ArgumentException(
      $"Type “{type}” is not value type.",
      paramName );

public static ArgumentException TYPE_IS_NOT_ENUMERATION( Type type, string paramName ) =>
   new ArgumentException(
      $"Type “{type}” is not enumeration.",
      paramName );

public static ArgumentException TYPE_IS_NOT_STD_VALUE_TYPE( Type type, string paramName ) =>
   new ArgumentException(
      $"Type “{type}” is not standard value type.",
      paramName );

public static ArgumentException TYPE_IS_NOT_INTEGRAL_TYPE( Type type, string paramName ) =>
   new ArgumentException(
      $"Type “{type}” is not integral type.",
      paramName );

public static ArgumentException TYPE_IS_NOT_INTEGRAL_SIGNED_NUMBER_TYPE(
   Type type, string paramName ) =>
   new ArgumentException(
      $"Type “{type}” is not integral signed number type.",
      paramName );

public static ArgumentException TYPE_IS_NOT_INTEGRAL_UNSIGNED_NUMBER_TYPE(
   Type type, string paramName ) =>
   new ArgumentException(
      $"Type “{type}” is not integral unsigned number type.",
      paramName );

//~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
} // type_argcheck_errors

} // user_rtx (.wasm)
