Ejemplo n.º 1
0
 static uint IBinaryInteger <uint> .LeadingZeroCount(uint value)
 => (uint)BitOperations.LeadingZeroCount(value);
Ejemplo n.º 2
0
 static int IBinaryInteger <int> .LeadingZeroCount(int value)
 => BitOperations.LeadingZeroCount((uint)value);
Ejemplo n.º 3
0
 /// <inheritdoc cref="IBinaryInteger{TSelf}.LeadingZeroCount(TSelf)" />
 public static uint LeadingZeroCount(uint value) => (uint)BitOperations.LeadingZeroCount(value);
Ejemplo n.º 4
0
 /// <inheritdoc cref="IBinaryInteger{TSelf}.LeadingZeroCount(TSelf)" />
 public static long LeadingZeroCount(long value) => BitOperations.LeadingZeroCount((ulong)value);
Ejemplo n.º 5
0
 static ushort IBinaryInteger <ushort> .LeadingZeroCount(ushort value)
 => (ushort)(BitOperations.LeadingZeroCount(value) - 16);
Ejemplo n.º 6
0
 /// <inheritdoc cref="IBinaryInteger{TSelf}.GetShortestBitLength()" />
 int IBinaryInteger <uint> .GetShortestBitLength() => (sizeof(uint) * 8) - BitOperations.LeadingZeroCount(m_value);
Ejemplo n.º 7
0
        //
        // IBinaryInteger
        //

        /// <inheritdoc cref="IBinaryInteger{TSelf}.LeadingZeroCount(TSelf)" />
        public static byte LeadingZeroCount(byte value) => (byte)(BitOperations.LeadingZeroCount(value) - 24);
Ejemplo n.º 8
0
 static byte IBinaryInteger <byte> .LeadingZeroCount(byte value)
 => (byte)(BitOperations.LeadingZeroCount(value) - 24);
Ejemplo n.º 9
0
 /// <inheritdoc cref="IBinaryInteger{TSelf}.LeadingZeroCount(TSelf)" />
 public static short LeadingZeroCount(short value) => (short)(BitOperations.LeadingZeroCount((ushort)value) - 16);
Ejemplo n.º 10
0
 /// <inheritdoc cref="IBinaryInteger{TSelf}.LeadingZeroCount(TSelf)" />
 public static int LeadingZeroCount(int value) => BitOperations.LeadingZeroCount((uint)value);
Ejemplo n.º 11
0
 static ulong IBinaryInteger <ulong> .LeadingZeroCount(ulong value)
 => (ulong)BitOperations.LeadingZeroCount(value);
Ejemplo n.º 12
0
 static long IBinaryInteger <long> .LeadingZeroCount(long value)
 => BitOperations.LeadingZeroCount((ulong)value);
Ejemplo n.º 13
0
 /// <inheritdoc cref="IBinaryInteger{TSelf}.LeadingZeroCount(TSelf)" />
 public static ulong LeadingZeroCount(ulong value) => (ulong)BitOperations.LeadingZeroCount(value);
Ejemplo n.º 14
0
 static sbyte IBinaryInteger <sbyte> .LeadingZeroCount(sbyte value)
 => (sbyte)(BitOperations.LeadingZeroCount((byte)value) - 24);
Ejemplo n.º 15
0
 static short IBinaryInteger <short> .LeadingZeroCount(short value)
 => (short)(BitOperations.LeadingZeroCount((ushort)value) - 16);