2 interfaces inheriting from IBinaryInteger
System.Private.CoreLib (2)
src\libraries\System.Private.CoreLib\src\System\IUtfChar.cs (1)
14IBinaryInteger<TSelf>
src\libraries\System.Private.CoreLib\src\System\Number.Parsing.cs (1)
30internal interface IBinaryIntegerParseAndFormatInfo<TSelf> : IBinaryInteger<TSelf>, IMinMaxValue<TSelf>
14 implementations of IBinaryInteger
System.Private.CoreLib (13)
src\libraries\System.Private.CoreLib\src\System\Byte.cs (1)
22IBinaryInteger<byte>,
src\libraries\System.Private.CoreLib\src\System\Char.cs (1)
28IBinaryInteger<char>,
src\libraries\System.Private.CoreLib\src\System\Int128.cs (1)
18: IBinaryInteger<Int128>,
src\libraries\System.Private.CoreLib\src\System\Int16.cs (1)
24IBinaryInteger<short>,
src\libraries\System.Private.CoreLib\src\System\Int32.cs (1)
24IBinaryInteger<int>,
src\libraries\System.Private.CoreLib\src\System\Int64.cs (1)
24IBinaryInteger<long>,
src\libraries\System.Private.CoreLib\src\System\IntPtr.cs (1)
33IBinaryInteger<nint>,
src\libraries\System.Private.CoreLib\src\System\SByte.cs (1)
24IBinaryInteger<sbyte>,
src\libraries\System.Private.CoreLib\src\System\UInt128.cs (1)
20: IBinaryInteger<UInt128>,
src\libraries\System.Private.CoreLib\src\System\UInt16.cs (1)
24IBinaryInteger<ushort>,
src\libraries\System.Private.CoreLib\src\System\UInt32.cs (1)
24IBinaryInteger<uint>,
src\libraries\System.Private.CoreLib\src\System\UInt64.cs (1)
24IBinaryInteger<ulong>,
src\libraries\System.Private.CoreLib\src\System\UIntPtr.cs (1)
33IBinaryInteger<nuint>,
System.Runtime.Numerics (1)
System\Numerics\BigInteger.cs (1)
22IBinaryInteger<BigInteger>,
386 references to IBinaryInteger
PresentationCore.Tests (1)
FluentAssertions\ComparisonHelpers.cs (1)
11where T : struct, IBinaryInteger<T>
System.Collections.Immutable (3)
System\Collections\Frozen\Integer\DenseIntegralFrozenDictionary.cs (3)
46where TKeyUnderlying : unmanaged, IBinaryInteger<TKeyUnderlying> 121where TKeyUnderlying : IBinaryInteger<TKeyUnderlying> 152where TKeyUnderlying : IBinaryInteger<TKeyUnderlying>
System.Formats.Tar (1)
System\Formats\Tar\TarHelpers.cs (1)
218internal static T ParseNumeric<T>(ReadOnlySpan<byte> buffer) where T : struct, INumber<T>, IBinaryInteger<T>
System.Linq (11)
System\Linq\Max.cs (4)
16private readonly struct MaxCalc<T> : IMinMaxCalc<T> where T : struct, IBinaryInteger<T> 28private static T? MaxInteger<T>(this IEnumerable<T?> source) where T : struct, IBinaryInteger<T> 524private static TResult MaxInteger<TSource, TResult>(this IEnumerable<TSource> source, Func<TSource, TResult> selector) where TResult : struct, IBinaryInteger<TResult> 556private static TResult? MaxInteger<TSource, TResult>(this IEnumerable<TSource> source, Func<TSource, TResult?> selector) where TResult : struct, IBinaryInteger<TResult>
System\Linq\MaxMin.cs (2)
14private interface IMinMaxCalc<T> where T : struct, IBinaryInteger<T> 23where T : struct, IBinaryInteger<T>
System\Linq\Min.cs (4)
16private readonly struct MinCalc<T> : IMinMaxCalc<T> where T : struct, IBinaryInteger<T> 28private static T? MinInteger<T>(this IEnumerable<T?> source) where T : struct, IBinaryInteger<T> 503private static TResult MinInteger<TSource, TResult>(this IEnumerable<TSource> source, Func<TSource, TResult> selector) where TResult : struct, IBinaryInteger<TResult> 535private static TResult? MinInteger<TSource, TResult>(this IEnumerable<TSource> source, Func<TSource, TResult?> selector) where TResult : struct, IBinaryInteger<TResult>
System\Linq\Sum.cs (1)
81where T : struct, IBinaryInteger<T>, ISignedNumber<T>, IMinMaxValue<T>
System.Net.Primitives (14)
src\libraries\Common\src\System\Net\IPv4AddressHelper.Common.cs (5)
24where TChar : unmanaged, IBinaryInteger<TChar> 35where TChar : unmanaged, IBinaryInteger<TChar> 101where TChar : unmanaged, IBinaryInteger<TChar> 128where TChar : unmanaged, IBinaryInteger<TChar> 214where TChar : unmanaged, IBinaryInteger<TChar>
src\libraries\Common\src\System\Net\IPv6AddressHelper.Common.cs (2)
99where TChar : unmanaged, IBinaryInteger<TChar> 312where TChar : unmanaged, IBinaryInteger<TChar>
System\Net\IPAddress.cs (1)
496private bool TryFormatCore<TChar>(Span<TChar> destination, out int charsWritten) where TChar : unmanaged, IBinaryInteger<TChar>
System\Net\IPAddressParser.cs (6)
20where TChar : unmanaged, IBinaryInteger<TChar> 38where TChar : unmanaged, IBinaryInteger<TChar> 67where TChar : unmanaged, IBinaryInteger<TChar> 91where TChar : unmanaged, IBinaryInteger<TChar> 150where TChar : unmanaged, IBinaryInteger<TChar> 195where TChar : unmanaged, IBinaryInteger<TChar>
System.Net.Quic (7)
src\libraries\Common\src\System\Net\IPv4AddressHelper.Common.cs (5)
24where TChar : unmanaged, IBinaryInteger<TChar> 35where TChar : unmanaged, IBinaryInteger<TChar> 101where TChar : unmanaged, IBinaryInteger<TChar> 128where TChar : unmanaged, IBinaryInteger<TChar> 214where TChar : unmanaged, IBinaryInteger<TChar>
src\libraries\Common\src\System\Net\IPv6AddressHelper.Common.cs (2)
99where TChar : unmanaged, IBinaryInteger<TChar> 312where TChar : unmanaged, IBinaryInteger<TChar>
System.Net.Security (7)
src\libraries\Common\src\System\Net\IPv4AddressHelper.Common.cs (5)
24where TChar : unmanaged, IBinaryInteger<TChar> 35where TChar : unmanaged, IBinaryInteger<TChar> 101where TChar : unmanaged, IBinaryInteger<TChar> 128where TChar : unmanaged, IBinaryInteger<TChar> 214where TChar : unmanaged, IBinaryInteger<TChar>
src\libraries\Common\src\System\Net\IPv6AddressHelper.Common.cs (2)
99where TChar : unmanaged, IBinaryInteger<TChar> 312where TChar : unmanaged, IBinaryInteger<TChar>
System.Numerics.Tensors (35)
System\Numerics\Tensors\netcore\Tensor.cs (10)
3975where T : IBinaryInteger<T> 3988where T : IBinaryInteger<T> 4830where T : IBinaryInteger<T> 4841where T : IBinaryInteger<T> 5009where T : IBinaryInteger<T> 5022where T : IBinaryInteger<T> 5036where T : IBinaryInteger<T> 5049where T : IBinaryInteger<T> 5507where T : IBinaryInteger<T> 5518where T : IBinaryInteger<T>
System\Numerics\Tensors\netcore\TensorOperation.cs (5)
1191where T : IBinaryInteger<T> 1670where T : IBinaryInteger<T> 1782where T : IBinaryInteger<T> 1796where T : IBinaryInteger<T> 2090where T : IBinaryInteger<T>
System\Numerics\Tensors\netcore\TensorPrimitives.ConvertToInteger.cs (2)
24where TTo : IBinaryInteger<TTo> => 30where TTo : IBinaryInteger<TTo>
System\Numerics\Tensors\netcore\TensorPrimitives.ConvertToIntegerNative.cs (2)
24where TTo : IBinaryInteger<TTo> => 30where TTo : IBinaryInteger<TTo>
System\Numerics\Tensors\netcore\TensorPrimitives.DivRem.cs (4)
30where T : IBinaryInteger<T> => 52where T : IBinaryInteger<T> => 74where T : IBinaryInteger<T> => 78private readonly struct DivRemOperator<T> : IBinaryInputBinaryOutput<T> where T : IBinaryInteger<T>
System\Numerics\Tensors\netcore\TensorPrimitives.HammingDistance.cs (1)
20public static long HammingBitDistance<T>(ReadOnlySpan<T> x, ReadOnlySpan<T> y) where T : IBinaryInteger<T>
System\Numerics\Tensors\netcore\TensorPrimitives.LeadingZeroCount.cs (2)
25where T : IBinaryInteger<T> => 29internal readonly unsafe struct LeadingZeroCountOperator<T> : IUnaryOperator<T, T> where T : IBinaryInteger<T>
System\Numerics\Tensors\netcore\TensorPrimitives.PopCount.cs (3)
17public static long PopCount<T>(ReadOnlySpan<T> x) where T : IBinaryInteger<T> 39where T : IBinaryInteger<T> => 43private readonly unsafe struct PopCountOperator<T> : IUnaryOperator<T, T> where T : IBinaryInteger<T>
System\Numerics\Tensors\netcore\TensorPrimitives.Rotate.cs (4)
22where T : IBinaryInteger<T> => 37where T : IBinaryInteger<T> => 41private readonly unsafe struct RotateLeftOperator<T>(int amount) : IStatefulUnaryOperator<T> where T : IBinaryInteger<T> 54private readonly unsafe struct RotateRightOperator<T>(int amount) : IStatefulUnaryOperator<T> where T : IBinaryInteger<T>
System\Numerics\Tensors\netcore\TensorPrimitives.TrailingZeroCount.cs (2)
24where T : IBinaryInteger<T> => 28private readonly unsafe struct TrailingZeroCountOperator<T> : IUnaryOperator<T, T> where T : IBinaryInteger<T>
System.Private.CoreLib (258)
src\libraries\System.Private.CoreLib\src\System\Byte.cs (18)
278/// <inheritdoc cref="IBinaryInteger{TSelf}.DivRem(TSelf, TSelf)" /> 281/// <inheritdoc cref="IBinaryInteger{TSelf}.LeadingZeroCount(TSelf)" /> 284/// <inheritdoc cref="IBinaryInteger{TSelf}.PopCount(TSelf)" /> 287/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateLeft(TSelf, int)" /> 290/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateRight(TSelf, int)" /> 293/// <inheritdoc cref="IBinaryInteger{TSelf}.TrailingZeroCount(TSelf)" /> 296/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadBigEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 297static bool IBinaryInteger<byte>.TryReadBigEndian(ReadOnlySpan<byte> source, bool isUnsigned, out byte value) 329/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadLittleEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 330static bool IBinaryInteger<byte>.TryReadLittleEndian(ReadOnlySpan<byte> source, bool isUnsigned, out byte value) 362/// <inheritdoc cref="IBinaryInteger{TSelf}.GetShortestBitLength()" /> 363int IBinaryInteger<byte>.GetShortestBitLength() => (sizeof(byte) * 8) - LeadingZeroCount(m_value); 365/// <inheritdoc cref="IBinaryInteger{TSelf}.GetByteCount()" /> 366int IBinaryInteger<byte>.GetByteCount() => sizeof(byte); 368/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteBigEndian(Span{byte}, out int)" /> 369bool IBinaryInteger<byte>.TryWriteBigEndian(Span<byte> destination, out int bytesWritten) 386/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteLittleEndian(Span{byte}, out int)" /> 387bool IBinaryInteger<byte>.TryWriteLittleEndian(Span<byte> destination, out int bytesWritten)
src\libraries\System.Private.CoreLib\src\System\Char.cs (22)
1162/// <inheritdoc cref="IBinaryInteger{TSelf}.LeadingZeroCount(TSelf)" /> 1163static char IBinaryInteger<char>.LeadingZeroCount(char value) => (char)(BitOperations.LeadingZeroCount(value) - 16); 1165/// <inheritdoc cref="IBinaryInteger{TSelf}.PopCount(TSelf)" /> 1166static char IBinaryInteger<char>.PopCount(char value) => (char)BitOperations.PopCount(value); 1168/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateLeft(TSelf, int)" /> 1169static char IBinaryInteger<char>.RotateLeft(char value, int rotateAmount) => (char)((value << (rotateAmount & 15)) | (value >> ((16 - rotateAmount) & 15))); 1171/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateRight(TSelf, int)" /> 1172static char IBinaryInteger<char>.RotateRight(char value, int rotateAmount) => (char)((value >> (rotateAmount & 15)) | (value << ((16 - rotateAmount) & 15))); 1174/// <inheritdoc cref="IBinaryInteger{TSelf}.TrailingZeroCount(TSelf)" /> 1175static char IBinaryInteger<char>.TrailingZeroCount(char value) => (char)(BitOperations.TrailingZeroCount(value << 16) - 16); 1177/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadBigEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 1178static bool IBinaryInteger<char>.TryReadBigEndian(ReadOnlySpan<byte> source, bool isUnsigned, out char value) 1227/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadLittleEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 1228static bool IBinaryInteger<char>.TryReadLittleEndian(ReadOnlySpan<byte> source, bool isUnsigned, out char value) 1275/// <inheritdoc cref="IBinaryInteger{TSelf}.GetShortestBitLength()" /> 1276int IBinaryInteger<char>.GetShortestBitLength() => (sizeof(char) * 8) - ushort.LeadingZeroCount(m_value); 1278/// <inheritdoc cref="IBinaryInteger{TSelf}.GetByteCount()" /> 1279int IBinaryInteger<char>.GetByteCount() => sizeof(char); 1281/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteBigEndian(Span{byte}, out int)" /> 1282bool IBinaryInteger<char>.TryWriteBigEndian(Span<byte> destination, out int bytesWritten) 1294/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteLittleEndian(Span{byte}, out int)" /> 1295bool IBinaryInteger<char>.TryWriteLittleEndian(Span<byte> destination, out int bytesWritten)
src\libraries\System.Private.CoreLib\src\System\Decimal.cs (2)
1122where TInteger : IBinaryInteger<TInteger> => TInteger.CreateSaturating(value); 1126where TInteger : IBinaryInteger<TInteger> => TInteger.CreateSaturating(value);
src\libraries\System.Private.CoreLib\src\System\Double.cs (2)
661where TInteger : IBinaryInteger<TInteger> => TInteger.CreateSaturating(value); 666where TInteger : IBinaryInteger<TInteger>
src\libraries\System.Private.CoreLib\src\System\Half.cs (2)
1317where TInteger : IBinaryInteger<TInteger> => TInteger.CreateSaturating(value); 1321where TInteger : IBinaryInteger<TInteger> => TInteger.CreateSaturating(value);
src\libraries\System.Private.CoreLib\src\System\Int128.cs (18)
711/// <inheritdoc cref="IBinaryInteger{TSelf}.DivRem(TSelf, TSelf)" /> 718/// <inheritdoc cref="IBinaryInteger{TSelf}.LeadingZeroCount(TSelf)" /> 733/// <inheritdoc cref="IBinaryInteger{TSelf}.PopCount(TSelf)" /> 737/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateLeft(TSelf, int)" /> 741/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateRight(TSelf, int)" /> 745/// <inheritdoc cref="IBinaryInteger{TSelf}.TrailingZeroCount(TSelf)" /> 755/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadBigEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 756static bool IBinaryInteger<Int128>.TryReadBigEndian(ReadOnlySpan<byte> source, bool isUnsigned, out Int128 value) 837/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadLittleEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 838static bool IBinaryInteger<Int128>.TryReadLittleEndian(ReadOnlySpan<byte> source, bool isUnsigned, out Int128 value) 922/// <inheritdoc cref="IBinaryInteger{TSelf}.GetShortestBitLength()" /> 923int IBinaryInteger<Int128>.GetShortestBitLength() 937/// <inheritdoc cref="IBinaryInteger{TSelf}.GetByteCount()" /> 938int IBinaryInteger<Int128>.GetByteCount() => Size; 940/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteBigEndian(Span{byte}, out int)" /> 941bool IBinaryInteger<Int128>.TryWriteBigEndian(Span<byte> destination, out int bytesWritten) 953/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteLittleEndian(Span{byte}, out int)" /> 954bool IBinaryInteger<Int128>.TryWriteLittleEndian(Span<byte> destination, out int bytesWritten)
src\libraries\System.Private.CoreLib\src\System\Int16.cs (18)
281/// <inheritdoc cref="IBinaryInteger{TSelf}.DivRem(TSelf, TSelf)" /> 284/// <inheritdoc cref="IBinaryInteger{TSelf}.LeadingZeroCount(TSelf)" /> 287/// <inheritdoc cref="IBinaryInteger{TSelf}.PopCount(TSelf)" /> 290/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateLeft(TSelf, int)" /> 293/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateRight(TSelf, int)" /> 296/// <inheritdoc cref="IBinaryInteger{TSelf}.TrailingZeroCount(TSelf)" /> 299/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadBigEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 300static bool IBinaryInteger<short>.TryReadBigEndian(ReadOnlySpan<byte> source, bool isUnsigned, out short value) 374/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadLittleEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 375static bool IBinaryInteger<short>.TryReadLittleEndian(ReadOnlySpan<byte> source, bool isUnsigned, out short value) 447/// <inheritdoc cref="IBinaryInteger{TSelf}.GetShortestBitLength()" /> 448int IBinaryInteger<short>.GetShortestBitLength() 462/// <inheritdoc cref="IBinaryInteger{TSelf}.GetByteCount()" /> 463int IBinaryInteger<short>.GetByteCount() => sizeof(short); 465/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteBigEndian(Span{byte}, out int)" /> 466bool IBinaryInteger<short>.TryWriteBigEndian(Span<byte> destination, out int bytesWritten) 478/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteLittleEndian(Span{byte}, out int)" /> 479bool IBinaryInteger<short>.TryWriteLittleEndian(Span<byte> destination, out int bytesWritten)
src\libraries\System.Private.CoreLib\src\System\Int32.cs (18)
296/// <inheritdoc cref="IBinaryInteger{TSelf}.DivRem(TSelf, TSelf)" /> 299/// <inheritdoc cref="IBinaryInteger{TSelf}.LeadingZeroCount(TSelf)" /> 303/// <inheritdoc cref="IBinaryInteger{TSelf}.PopCount(TSelf)" /> 307/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateLeft(TSelf, int)" /> 311/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateRight(TSelf, int)" /> 315/// <inheritdoc cref="IBinaryInteger{TSelf}.TrailingZeroCount(TSelf)" /> 319/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadBigEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 320static bool IBinaryInteger<int>.TryReadBigEndian(ReadOnlySpan<byte> source, bool isUnsigned, out int value) 401/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadLittleEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 402static bool IBinaryInteger<int>.TryReadLittleEndian(ReadOnlySpan<byte> source, bool isUnsigned, out int value) 486/// <inheritdoc cref="IBinaryInteger{TSelf}.GetShortestBitLength()" /> 487int IBinaryInteger<int>.GetShortestBitLength() 501/// <inheritdoc cref="IBinaryInteger{TSelf}.GetByteCount()" /> 502int IBinaryInteger<int>.GetByteCount() => sizeof(int); 504/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteBigEndian(Span{byte}, out int)" /> 505bool IBinaryInteger<int>.TryWriteBigEndian(Span<byte> destination, out int bytesWritten) 517/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteLittleEndian(Span{byte}, out int)" /> 518bool IBinaryInteger<int>.TryWriteLittleEndian(Span<byte> destination, out int bytesWritten)
src\libraries\System.Private.CoreLib\src\System\Int64.cs (18)
293/// <inheritdoc cref="IBinaryInteger{TSelf}.DivRem(TSelf, TSelf)" /> 296/// <inheritdoc cref="IBinaryInteger{TSelf}.LeadingZeroCount(TSelf)" /> 300/// <inheritdoc cref="IBinaryInteger{TSelf}.PopCount(TSelf)" /> 304/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateLeft(TSelf, int)" /> 308/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateRight(TSelf, int)" /> 312/// <inheritdoc cref="IBinaryInteger{TSelf}.TrailingZeroCount(TSelf)" /> 316/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadBigEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 317static bool IBinaryInteger<long>.TryReadBigEndian(ReadOnlySpan<byte> source, bool isUnsigned, out long value) 398/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadLittleEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 399static bool IBinaryInteger<long>.TryReadLittleEndian(ReadOnlySpan<byte> source, bool isUnsigned, out long value) 483/// <inheritdoc cref="IBinaryInteger{TSelf}.GetShortestBitLength()" /> 484int IBinaryInteger<long>.GetShortestBitLength() 498/// <inheritdoc cref="IBinaryInteger{TSelf}.GetByteCount()" /> 499int IBinaryInteger<long>.GetByteCount() => sizeof(long); 501/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteBigEndian(Span{byte}, out int)" /> 502bool IBinaryInteger<long>.TryWriteBigEndian(Span<byte> destination, out int bytesWritten) 514/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteLittleEndian(Span{byte}, out int)" /> 515bool IBinaryInteger<long>.TryWriteLittleEndian(Span<byte> destination, out int bytesWritten)
src\libraries\System.Private.CoreLib\src\System\IntPtr.cs (18)
298/// <inheritdoc cref="IBinaryInteger{TSelf}.DivRem(TSelf, TSelf)" /> 301/// <inheritdoc cref="IBinaryInteger{TSelf}.LeadingZeroCount(TSelf)" /> 305/// <inheritdoc cref="IBinaryInteger{TSelf}.PopCount(TSelf)" /> 309/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateLeft(TSelf, int)" /> 313/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateRight(TSelf, int)" /> 317/// <inheritdoc cref="IBinaryInteger{TSelf}.TrailingZeroCount(TSelf)" /> 321/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadBigEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 322static bool IBinaryInteger<nint>.TryReadBigEndian(ReadOnlySpan<byte> source, bool isUnsigned, out nint value) 403/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadLittleEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 404static bool IBinaryInteger<nint>.TryReadLittleEndian(ReadOnlySpan<byte> source, bool isUnsigned, out nint value) 488/// <inheritdoc cref="IBinaryInteger{TSelf}.GetShortestBitLength()" /> 489int IBinaryInteger<nint>.GetShortestBitLength() 503/// <inheritdoc cref="IBinaryInteger{TSelf}.GetByteCount()" /> 504int IBinaryInteger<nint>.GetByteCount() => sizeof(nint_t); 506/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteBigEndian(Span{byte}, out int)" /> 507bool IBinaryInteger<nint>.TryWriteBigEndian(Span<byte> destination, out int bytesWritten) 519/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteLittleEndian(Span{byte}, out int)" /> 520bool IBinaryInteger<nint>.TryWriteLittleEndian(Span<byte> destination, out int bytesWritten)
src\libraries\System.Private.CoreLib\src\System\Numerics\IBinaryInteger.cs (1)
11where TSelf : IBinaryInteger<TSelf>?
src\libraries\System.Private.CoreLib\src\System\Numerics\IFloatingPoint.cs (2)
24where TInteger : IBinaryInteger<TInteger> 34where TInteger : IBinaryInteger<TInteger>
src\libraries\System.Private.CoreLib\src\System\Numerics\TotalOrderIeee754Comparer.cs (1)
71where TInteger : struct, IBinaryInteger<TInteger>, ISignedNumber<TInteger>
src\libraries\System.Private.CoreLib\src\System\Runtime\InteropServices\NFloat.cs (2)
985where TInteger : IBinaryInteger<TInteger> => TInteger.CreateSaturating(value); 989where TInteger : IBinaryInteger<TInteger> => TInteger.CreateSaturating(value);
src\libraries\System.Private.CoreLib\src\System\SByte.cs (18)
284/// <inheritdoc cref="IBinaryInteger{TSelf}.DivRem(TSelf, TSelf)" /> 287/// <inheritdoc cref="IBinaryInteger{TSelf}.LeadingZeroCount(TSelf)" /> 290/// <inheritdoc cref="IBinaryInteger{TSelf}.PopCount(TSelf)" /> 293/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateLeft(TSelf, int)" /> 296/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateRight(TSelf, int)" /> 299/// <inheritdoc cref="IBinaryInteger{TSelf}.TrailingZeroCount(TSelf)" /> 302/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadBigEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 303static bool IBinaryInteger<sbyte>.TryReadBigEndian(ReadOnlySpan<byte> source, bool isUnsigned, out sbyte value) 355/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadLittleEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 356static bool IBinaryInteger<sbyte>.TryReadLittleEndian(ReadOnlySpan<byte> source, bool isUnsigned, out sbyte value) 408/// <inheritdoc cref="IBinaryInteger{TSelf}.GetShortestBitLength()" /> 409int IBinaryInteger<sbyte>.GetShortestBitLength() 423/// <inheritdoc cref="IBinaryInteger{TSelf}.GetByteCount()" /> 424int IBinaryInteger<sbyte>.GetByteCount() => sizeof(sbyte); 426/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteBigEndian(Span{byte}, out int)" /> 427bool IBinaryInteger<sbyte>.TryWriteBigEndian(Span<byte> destination, out int bytesWritten) 440/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteLittleEndian(Span{byte}, out int)" /> 441bool IBinaryInteger<sbyte>.TryWriteLittleEndian(Span<byte> destination, out int bytesWritten)
src\libraries\System.Private.CoreLib\src\System\Single.cs (2)
656where TInteger : IBinaryInteger<TInteger> => TInteger.CreateSaturating(value); 661where TInteger : IBinaryInteger<TInteger>
src\libraries\System.Private.CoreLib\src\System\Text\Ascii.CaseConversion.cs (5)
158where TFrom : unmanaged, IBinaryInteger<TFrom> 159where TTo : unmanaged, IBinaryInteger<TTo> 193where T : unmanaged, IBinaryInteger<T> 207where TFrom : unmanaged, IBinaryInteger<TFrom> 208where TTo : unmanaged, IBinaryInteger<TTo>
src\libraries\System.Private.CoreLib\src\System\Text\Ascii.Trimming.cs (1)
41where T : unmanaged, IBinaryInteger<T>
src\libraries\System.Private.CoreLib\src\System\UInt128.cs (18)
778/// <inheritdoc cref="IBinaryInteger{TSelf}.DivRem(TSelf, TSelf)" /> 785/// <inheritdoc cref="IBinaryInteger{TSelf}.LeadingZeroCount(TSelf)" /> 800/// <inheritdoc cref="IBinaryInteger{TSelf}.PopCount(TSelf)" /> 804/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateLeft(TSelf, int)" /> 808/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateRight(TSelf, int)" /> 812/// <inheritdoc cref="IBinaryInteger{TSelf}.TrailingZeroCount(TSelf)" /> 822/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadBigEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 823static bool IBinaryInteger<UInt128>.TryReadBigEndian(ReadOnlySpan<byte> source, bool isUnsigned, out UInt128 value) 879/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadLittleEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 880static bool IBinaryInteger<UInt128>.TryReadLittleEndian(ReadOnlySpan<byte> source, bool isUnsigned, out UInt128 value) 937/// <inheritdoc cref="IBinaryInteger{TSelf}.GetShortestBitLength()" /> 938int IBinaryInteger<UInt128>.GetShortestBitLength() 943/// <inheritdoc cref="IBinaryInteger{TSelf}.GetByteCount()" /> 944int IBinaryInteger<UInt128>.GetByteCount() => Size; 946/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteBigEndian(Span{byte}, out int)" /> 947bool IBinaryInteger<UInt128>.TryWriteBigEndian(Span<byte> destination, out int bytesWritten) 959/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteLittleEndian(Span{byte}, out int)" /> 960bool IBinaryInteger<UInt128>.TryWriteLittleEndian(Span<byte> destination, out int bytesWritten)
src\libraries\System.Private.CoreLib\src\System\UInt16.cs (18)
275/// <inheritdoc cref="IBinaryInteger{TSelf}.DivRem(TSelf, TSelf)" /> 278/// <inheritdoc cref="IBinaryInteger{TSelf}.LeadingZeroCount(TSelf)" /> 281/// <inheritdoc cref="IBinaryInteger{TSelf}.PopCount(TSelf)" /> 284/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateLeft(TSelf, int)" /> 287/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateRight(TSelf, int)" /> 290/// <inheritdoc cref="IBinaryInteger{TSelf}.TrailingZeroCount(TSelf)" /> 293/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadBigEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 294static bool IBinaryInteger<ushort>.TryReadBigEndian(ReadOnlySpan<byte> source, bool isUnsigned, out ushort value) 343/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadLittleEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 344static bool IBinaryInteger<ushort>.TryReadLittleEndian(ReadOnlySpan<byte> source, bool isUnsigned, out ushort value) 391/// <inheritdoc cref="IBinaryInteger{TSelf}.GetShortestBitLength()" /> 392int IBinaryInteger<ushort>.GetShortestBitLength() => (sizeof(ushort) * 8) - LeadingZeroCount(m_value); 394/// <inheritdoc cref="IBinaryInteger{TSelf}.GetByteCount()" /> 395int IBinaryInteger<ushort>.GetByteCount() => sizeof(ushort); 397/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteBigEndian(Span{byte}, out int)" /> 398bool IBinaryInteger<ushort>.TryWriteBigEndian(Span<byte> destination, out int bytesWritten) 410/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteLittleEndian(Span{byte}, out int)" /> 411bool IBinaryInteger<ushort>.TryWriteLittleEndian(Span<byte> destination, out int bytesWritten)
src\libraries\System.Private.CoreLib\src\System\UInt32.cs (18)
291/// <inheritdoc cref="IBinaryInteger{TSelf}.DivRem(TSelf, TSelf)" /> 294/// <inheritdoc cref="IBinaryInteger{TSelf}.LeadingZeroCount(TSelf)" /> 298/// <inheritdoc cref="IBinaryInteger{TSelf}.PopCount(TSelf)" /> 302/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateLeft(TSelf, int)" /> 306/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateRight(TSelf, int)" /> 310/// <inheritdoc cref="IBinaryInteger{TSelf}.TrailingZeroCount(TSelf)" /> 314/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadBigEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 315static bool IBinaryInteger<uint>.TryReadBigEndian(ReadOnlySpan<byte> source, bool isUnsigned, out uint value) 371/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadLittleEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 372static bool IBinaryInteger<uint>.TryReadLittleEndian(ReadOnlySpan<byte> source, bool isUnsigned, out uint value) 429/// <inheritdoc cref="IBinaryInteger{TSelf}.GetShortestBitLength()" /> 430int IBinaryInteger<uint>.GetShortestBitLength() => (sizeof(uint) * 8) - BitOperations.LeadingZeroCount(m_value); 432/// <inheritdoc cref="IBinaryInteger{TSelf}.GetByteCount()" /> 433int IBinaryInteger<uint>.GetByteCount() => sizeof(uint); 435/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteBigEndian(Span{byte}, out int)" /> 436bool IBinaryInteger<uint>.TryWriteBigEndian(Span<byte> destination, out int bytesWritten) 448/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteLittleEndian(Span{byte}, out int)" /> 449bool IBinaryInteger<uint>.TryWriteLittleEndian(Span<byte> destination, out int bytesWritten)
src\libraries\System.Private.CoreLib\src\System\UInt64.cs (18)
290/// <inheritdoc cref="IBinaryInteger{TSelf}.DivRem(TSelf, TSelf)" /> 293/// <inheritdoc cref="IBinaryInteger{TSelf}.LeadingZeroCount(TSelf)" /> 297/// <inheritdoc cref="IBinaryInteger{TSelf}.PopCount(TSelf)" /> 301/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateLeft(TSelf, int)" /> 305/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateRight(TSelf, int)" /> 309/// <inheritdoc cref="IBinaryInteger{TSelf}.TrailingZeroCount(TSelf)" /> 313/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadBigEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 314static bool IBinaryInteger<ulong>.TryReadBigEndian(ReadOnlySpan<byte> source, bool isUnsigned, out ulong value) 370/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadLittleEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 371static bool IBinaryInteger<ulong>.TryReadLittleEndian(ReadOnlySpan<byte> source, bool isUnsigned, out ulong value) 428/// <inheritdoc cref="IBinaryInteger{TSelf}.GetShortestBitLength()" /> 429int IBinaryInteger<ulong>.GetShortestBitLength() => (sizeof(ulong) * 8) - BitOperations.LeadingZeroCount(m_value); 431/// <inheritdoc cref="IBinaryInteger{TSelf}.GetByteCount()" /> 432int IBinaryInteger<ulong>.GetByteCount() => sizeof(ulong); 434/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteBigEndian(Span{byte}, out int)" /> 435bool IBinaryInteger<ulong>.TryWriteBigEndian(Span<byte> destination, out int bytesWritten) 447/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteLittleEndian(Span{byte}, out int)" /> 448bool IBinaryInteger<ulong>.TryWriteLittleEndian(Span<byte> destination, out int bytesWritten)
src\libraries\System.Private.CoreLib\src\System\UIntPtr.cs (18)
294/// <inheritdoc cref="IBinaryInteger{TSelf}.DivRem(TSelf, TSelf)" /> 297/// <inheritdoc cref="IBinaryInteger{TSelf}.LeadingZeroCount(TSelf)" /> 301/// <inheritdoc cref="IBinaryInteger{TSelf}.PopCount(TSelf)" /> 305/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateLeft(TSelf, int)" /> 309/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateRight(TSelf, int)" /> 313/// <inheritdoc cref="IBinaryInteger{TSelf}.TrailingZeroCount(TSelf)" /> 317/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadBigEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 318static bool IBinaryInteger<nuint>.TryReadBigEndian(ReadOnlySpan<byte> source, bool isUnsigned, out nuint value) 374/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadLittleEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 375static bool IBinaryInteger<nuint>.TryReadLittleEndian(ReadOnlySpan<byte> source, bool isUnsigned, out nuint value) 432/// <inheritdoc cref="IBinaryInteger{TSelf}.GetShortestBitLength()" /> 433int IBinaryInteger<nuint>.GetShortestBitLength() => (sizeof(nuint_t) * 8) - BitOperations.LeadingZeroCount(_value); 435/// <inheritdoc cref="IBinaryInteger{TSelf}.GetByteCount()" /> 436int IBinaryInteger<nuint>.GetByteCount() => sizeof(nuint_t); 438/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteBigEndian(Span{byte}, out int)" /> 439bool IBinaryInteger<nuint>.TryWriteBigEndian(Span<byte> destination, out int bytesWritten) 451/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteLittleEndian(Span{byte}, out int)" /> 452bool IBinaryInteger<nuint>.TryWriteLittleEndian(Span<byte> destination, out int bytesWritten)
System.Private.Uri (7)
src\libraries\Common\src\System\Net\IPv4AddressHelper.Common.cs (5)
24where TChar : unmanaged, IBinaryInteger<TChar> 35where TChar : unmanaged, IBinaryInteger<TChar> 101where TChar : unmanaged, IBinaryInteger<TChar> 128where TChar : unmanaged, IBinaryInteger<TChar> 214where TChar : unmanaged, IBinaryInteger<TChar>
src\libraries\Common\src\System\Net\IPv6AddressHelper.Common.cs (2)
99where TChar : unmanaged, IBinaryInteger<TChar> 312where TChar : unmanaged, IBinaryInteger<TChar>
System.Private.Windows.Core.TestUtilities (7)
ComparisonHelpers.cs (1)
11where T : struct, IBinaryInteger<T>
XUnit\IntegerDataAttribute.cs (1)
12where TNumber : struct, IBinaryInteger<TNumber>, IMinMaxValue<TNumber>
XUnit\PositiveNumberDataAttribute.cs (1)
12: CommonMemberDataAttribute where TNumber : struct, IBinaryInteger<TNumber>, IMinMaxValue<TNumber>
XUnit\TestData.cs (4)
24where T : struct, IBinaryInteger<T>, IMinMaxValue<T> 31where T : struct, IBinaryInteger<T>, IMinMaxValue<T> 53where T : struct, IBinaryInteger<T>, IMinMaxValue<T> 76where T : struct, IBinaryInteger<T>, IMinMaxValue<T>
System.Runtime (1)
artifacts\obj\System.Runtime\Debug\net10.0\System.Runtime.Forwards.cs (1)
374[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Numerics.IBinaryInteger<>))]
System.Runtime.Numerics (23)
System\Number.BigInteger.cs (4)
142where TChar : unmanaged, IBinaryInteger<TChar> 1210where TChar : unmanaged, IBinaryInteger<TChar> 1255where TChar : unmanaged, IBinaryInteger<TChar> 1291where TChar : unmanaged, IBinaryInteger<TChar>
System\Numerics\BigInteger.cs (18)
3160/// <inheritdoc cref="IBinaryInteger{TSelf}.DivRem(TSelf, TSelf)" /> 3167/// <inheritdoc cref="IBinaryInteger{TSelf}.LeadingZeroCount(TSelf)" /> 3183/// <inheritdoc cref="IBinaryInteger{TSelf}.PopCount(TSelf)" /> 3238/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateLeft(TSelf, int)" /> 3392/// <inheritdoc cref="IBinaryInteger{TSelf}.RotateRight(TSelf, int)" /> 3539/// <inheritdoc cref="IBinaryInteger{TSelf}.TrailingZeroCount(TSelf)" /> 3567/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadBigEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 3568static bool IBinaryInteger<BigInteger>.TryReadBigEndian(ReadOnlySpan<byte> source, bool isUnsigned, out BigInteger value) 3574/// <inheritdoc cref="IBinaryInteger{TSelf}.TryReadLittleEndian(ReadOnlySpan{byte}, bool, out TSelf)" /> 3575static bool IBinaryInteger<BigInteger>.TryReadLittleEndian(ReadOnlySpan<byte> source, bool isUnsigned, out BigInteger value) 3581/// <inheritdoc cref="IBinaryInteger{TSelf}.GetShortestBitLength()" /> 3582int IBinaryInteger<BigInteger>.GetShortestBitLength() 3630/// <inheritdoc cref="IBinaryInteger{TSelf}.GetByteCount()" /> 3631int IBinaryInteger<BigInteger>.GetByteCount() => GetGenericMathByteCount(); 3633/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteBigEndian(Span{byte}, out int)" /> 3634bool IBinaryInteger<BigInteger>.TryWriteBigEndian(Span<byte> destination, out int bytesWritten) 3735/// <inheritdoc cref="IBinaryInteger{TSelf}.TryWriteLittleEndian(Span{byte}, out int)" /> 3736bool IBinaryInteger<BigInteger>.TryWriteLittleEndian(Span<byte> destination, out int bytesWritten)
System\Numerics\Complex.cs (1)
2207private bool TryFormatCore<TChar>(Span<TChar> destination, out int charsWritten, ReadOnlySpan<char> format, IFormatProvider? provider) where TChar : unmanaged, IBinaryInteger<TChar>
System.Text.RegularExpressions (1)
System\Text\RegularExpressions\Symbolic\MintermClassifier.cs (1)
80static T[] CreateLookup<T>(BDD[] minterms, ReadOnlySpan<object> charRangesPerMinterm, int _maxChar) where T : IBinaryInteger<T>
System.Threading.Tasks.Parallel (9)
System\Threading\Tasks\Parallel.cs (1)
921where TInt : struct, IBinaryInteger<TInt>, IMinMaxValue<TInt>
System\Threading\Tasks\Parallel.ForEachAsync.cs (4)
21where T : notnull, IBinaryInteger<T> 39where T : notnull, IBinaryInteger<T> 57where T : notnull, IBinaryInteger<T> 78where T : notnull, IBinaryInteger<T>
System\Threading\Tasks\ParallelLoopState.cs (3)
184internal static void Break<TInt>(TInt iteration, ParallelLoopStateFlags<TInt> pflags) where TInt : struct, IBinaryInteger<TInt>, IMinMaxValue<TInt> 224internal sealed class ParallelLoopState<TInt> : ParallelLoopState where TInt : struct, IBinaryInteger<TInt>, IMinMaxValue<TInt> 350where TInt : struct, IBinaryInteger<TInt>, IMinMaxValue<TInt>
System\Threading\Tasks\ParallelRangeManager.cs (1)
176internal bool FindNewWork<TInt>(out TInt fromInclusive, out TInt toExclusive) where TInt : struct, IBinaryInteger<TInt>, IMinMaxValue<TInt>
System.Windows.Forms.Design (1)
System\ComponentModel\Design\Serialization\CodeDomSerializerBase.cs (1)
1414static object ExecuteBinaryOperator<T>(T leftValue, T rightValue, CodeBinaryOperatorType op) where T : IBinaryInteger<T>