9 implementations of Abs
System.Private.CoreLib (7)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Byte.cs (1)
554static byte INumberBase<byte>.Abs(byte value) => value;
src\runtime\src\libraries\System.Private.CoreLib\src\System\Char.cs (1)
1491static char INumberBase<char>.Abs(char value) => value;
src\runtime\src\libraries\System.Private.CoreLib\src\System\UInt128.cs (1)
1479static UInt128 INumberBase<UInt128>.Abs(UInt128 value) => value;
src\runtime\src\libraries\System.Private.CoreLib\src\System\UInt16.cs (1)
559static ushort INumberBase<ushort>.Abs(ushort value) => value;
src\runtime\src\libraries\System.Private.CoreLib\src\System\UInt32.cs (1)
624static uint INumberBase<uint>.Abs(uint value) => value;
src\runtime\src\libraries\System.Private.CoreLib\src\System\UInt64.cs (1)
631static ulong INumberBase<ulong>.Abs(ulong value) => value;
src\runtime\src\libraries\System.Private.CoreLib\src\System\UIntPtr.cs (1)
630static nuint INumberBase<nuint>.Abs(nuint value) => value;
System.Runtime.Numerics (2)
System\Numerics\Complex.cs (1)
523static Complex INumberBase<Complex>.Abs(Complex value) => Abs(value);
System\Numerics\Complex.Generic.cs (1)
1185static Complex<T> INumberBase<Complex<T>>.Abs(Complex<T> value) => Abs(value);
42 references to Abs
System.Numerics.Tensors (5)
System\Numerics\Tensors\netcore\TensorOperation.cs (3)
522destination = T.Abs(x); 2133T diff = T.Abs(x - y); 2141T diff = T.Abs(x[i] - y);
System\Numerics\Tensors\netcore\TensorPrimitives.Abs.cs (1)
45public static T Invoke(T x) => T.Abs(x);
System\Numerics\Tensors\netcore\TensorPrimitives.StdDev.cs (1)
44diff = T.Abs(diff); // only relevant to non-vectorizable types
System.Private.CoreLib (20)
src\runtime\src\libraries\System.Private.CoreLib\src\System\Byte.cs (1)
553/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Char.cs (1)
1490/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Decimal.cs (1)
1278/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Double.cs (1)
1059/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Half.cs (1)
1806/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Int128.cs (1)
1269/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Int16.cs (1)
653/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Int32.cs (1)
695/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Int64.cs (1)
692/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\IntPtr.cs (1)
715/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Number.Rounding.cs (1)
58TNumber av = TNumber.Abs(value);
src\runtime\src\libraries\System.Private.CoreLib\src\System\Numerics\BFloat16.cs (1)
1395/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\NFloat.cs (1)
1217/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\SByte.cs (1)
632/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\Single.cs (1)
1054/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\UInt128.cs (1)
1478/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\UInt16.cs (1)
558/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\UInt32.cs (1)
623/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\UInt64.cs (1)
630/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />
src\runtime\src\libraries\System.Private.CoreLib\src\System\UIntPtr.cs (1)
629/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />
System.Private.Windows.Core.TestUtilities (3)
ComparisonHelpers.cs (2)
16return T.Abs(x > y ? x - y : y - x) <= variance; 107return T.Abs(x > y ? x - y : y - x) <= variance;
XUnit\FloatingPointToleranceComparerer.cs (1)
18public FloatingPointToleranceComparerer(T tolerance) => _tolerance = T.Abs(tolerance);
System.Runtime.Numerics (14)
System\Numerics\Complex.cs (1)
522/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />
System\Numerics\Complex.Generic.cs (13)
293if (T.Abs(d) < T.Abs(c)) 519Asin_Internal(T.Abs(value.Real), T.Abs(value.Imaginary), out T b, out T bPrime, out T v); 549T absB = T.Abs(b); 646Asin_Internal(T.Abs(value.Real), T.Abs(value.Imaginary), out T b, out T bPrime, out T v); 675T absY = T.Abs(y); 745if (T.Abs(value.m_imaginary) <= T.CreateChecked(4)) 812T absB = T.Abs(b); 1055if ((T.Abs(realCopy) >= s_sqrtRescaleThreshold) || (T.Abs(imaginaryCopy) >= s_sqrtRescaleThreshold)) 1184/// <inheritdoc cref="INumberBase{TSelf}.Abs(TSelf)" />