Skip to content
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Update comment
  • Loading branch information
dakersnar committed Nov 2, 2022
commit 94c95d7defdfc59dcc808f64e9ebdcb11c16135e
Original file line number Diff line number Diff line change
Expand Up @@ -3481,9 +3481,8 @@ public static BigInteger TrailingZeroCount(BigInteger value)

ulong result = 0;

// As explained in https://github.com/dotnet/runtime/issues/77720, both positive values and
// their two's-compliment negative representation will share the same TrailingZeroCount,
// so the stored sign of value does not matter
// Both positive values and their two's-compliment negative representation will share the same TrailingZeroCount,
// so the stored sign of value does not matter and both cases can be handled in the same way

uint part = value._bits[0];

Expand Down