25 implementations of TryConvertFromChecked
System.Private.CoreLib (22)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Byte.cs (1)
681
static bool INumberBase<byte>.
TryConvertFromChecked
<TOther>(TOther value, out byte result) => TryConvertFromChecked(value, out result);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Char.cs (1)
1565
static bool INumberBase<char>.
TryConvertFromChecked
<TOther>(TOther value, out char result)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Decimal.cs (1)
1469
static bool INumberBase<decimal>.
TryConvertFromChecked
<TOther>(TOther value, out decimal result) => TryConvertFromChecked(value, out result);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Double.cs (1)
1228
static bool INumberBase<double>.
TryConvertFromChecked
<TOther>(TOther value, out double result)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Half.cs (1)
1962
static bool INumberBase<Half>.
TryConvertFromChecked
<TOther>(TOther value, out Half result)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Int128.cs (1)
1483
static bool INumberBase<Int128>.
TryConvertFromChecked
<TOther>(TOther value, out Int128 result) => TryConvertFromChecked(value, out result);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Int16.cs (1)
855
static bool INumberBase<short>.
TryConvertFromChecked
<TOther>(TOther value, out short result) => TryConvertFromChecked(value, out result);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Int32.cs (1)
897
static bool INumberBase<int>.
TryConvertFromChecked
<TOther>(TOther value, out int result) => TryConvertFromChecked(value, out result);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Int64.cs (1)
894
static bool INumberBase<long>.
TryConvertFromChecked
<TOther>(TOther value, out long result) => TryConvertFromChecked(value, out result);
src\runtime\src\libraries\System.Private.CoreLib\src\System\IntPtr.cs (1)
917
static bool INumberBase<nint>.
TryConvertFromChecked
<TOther>(TOther value, out nint result) => TryConvertFromChecked(value, out result);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Numerics\BFloat16.cs (1)
1548
static bool INumberBase<BFloat16>.
TryConvertFromChecked
<TOther>(TOther value, out BFloat16 result)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Numerics\Decimal128.cs (1)
1362
static bool INumberBase<Decimal128>.
TryConvertFromChecked
<TOther>(TOther value, out Decimal128 result) => TryConvertFrom(value, out result);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Numerics\Decimal32.cs (1)
1373
static bool INumberBase<Decimal32>.
TryConvertFromChecked
<TOther>(TOther value, out Decimal32 result) => TryConvertFrom(value, out result);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Numerics\Decimal64.cs (1)
1366
static bool INumberBase<Decimal64>.
TryConvertFromChecked
<TOther>(TOther value, out Decimal64 result) => TryConvertFrom(value, out result);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\NFloat.cs (1)
1321
static bool INumberBase<NFloat>.
TryConvertFromChecked
<TOther>(TOther value, out NFloat result)
src\runtime\src\libraries\System.Private.CoreLib\src\System\SByte.cs (1)
834
static bool INumberBase<sbyte>.
TryConvertFromChecked
<TOther>(TOther value, out sbyte result) => TryConvertFromChecked(value, out result);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Single.cs (1)
1245
static bool INumberBase<float>.
TryConvertFromChecked
<TOther>(TOther value, out float result)
src\runtime\src\libraries\System.Private.CoreLib\src\System\UInt128.cs (1)
1606
static bool INumberBase<UInt128>.
TryConvertFromChecked
<TOther>(TOther value, out UInt128 result) => TryConvertFromChecked(value, out result);
src\runtime\src\libraries\System.Private.CoreLib\src\System\UInt16.cs (1)
686
static bool INumberBase<ushort>.
TryConvertFromChecked
<TOther>(TOther value, out ushort result) => TryConvertFromChecked(value, out result);
src\runtime\src\libraries\System.Private.CoreLib\src\System\UInt32.cs (1)
751
static bool INumberBase<uint>.
TryConvertFromChecked
<TOther>(TOther value, out uint result) => TryConvertFromChecked(value, out result);
src\runtime\src\libraries\System.Private.CoreLib\src\System\UInt64.cs (1)
758
static bool INumberBase<ulong>.
TryConvertFromChecked
<TOther>(TOther value, out ulong result) => TryConvertFromChecked(value, out result);
src\runtime\src\libraries\System.Private.CoreLib\src\System\UIntPtr.cs (1)
757
static bool INumberBase<nuint>.
TryConvertFromChecked
<TOther>(TOther value, out nuint result) => TryConvertFromChecked(value, out result);
System.Runtime.Numerics (3)
System\Numerics\BigInteger.cs (1)
4269
static bool INumberBase<BigInteger>.
TryConvertFromChecked
<TOther>(TOther value, out BigInteger result) => TryConvertFromChecked(value, out result);
System\Numerics\Complex.cs (1)
725
static bool INumberBase<Complex>.
TryConvertFromChecked
<TOther>(TOther value, out Complex result)
System\Numerics\Complex.Generic.cs (1)
1627
static bool INumberBase<Complex<T>>.
TryConvertFromChecked
<TOther>(TOther value, out Complex<T> result)
28 references to TryConvertFromChecked
System.Private.CoreLib (23)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Byte.cs (1)
679
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Char.cs (1)
1563
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Decimal.cs (1)
1467
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Double.cs (1)
1226
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Half.cs (1)
1960
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Int128.cs (1)
1481
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Int16.cs (1)
853
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Int32.cs (1)
895
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Int64.cs (1)
892
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\IntPtr.cs (1)
915
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Numerics\BFloat16.cs (1)
1546
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Numerics\Decimal128.cs (1)
1360
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Numerics\Decimal32.cs (1)
1371
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Numerics\Decimal64.cs (1)
1364
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Numerics\INumberBase.cs (1)
67
else if (!TSelf.
TryConvertFromChecked
(value, out result) && !TOther.TryConvertToChecked<TSelf>(value, out result))
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\NFloat.cs (1)
1319
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\SByte.cs (1)
832
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Single.cs (1)
1243
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\UInt128.cs (1)
1604
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\UInt16.cs (1)
684
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\UInt32.cs (1)
749
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\UInt64.cs (1)
756
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\UIntPtr.cs (1)
755
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
System.Runtime.Numerics (5)
System\Numerics\BigInteger.cs (1)
4267
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
System\Numerics\Complex.cs (1)
723
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
System\Numerics\Complex.Generic.cs (3)
1625
/// <inheritdoc cref="INumberBase{TSelf}.
TryConvertFromChecked
{TOther}(TOther, out TSelf)" />
1662
if (T.
TryConvertFromChecked
(value, out T? realResult) && realResult is not null)
1825
return TOther.
TryConvertFromChecked
<T>(value.m_real, out result);