X-Git-Url: https://git.sesse.net/?a=blobdiff_plain;f=src%2Fbitboard.h;h=35904377ea62d633f55adc83b749b55f8e8f85a7;hb=3b14b17664b30933e55d0fb1c8248ddab8b49110;hp=b99cc2597ceb7959709b50c1dbfa3514e2479383;hpb=e304db9d1ecf6a2318708483c90fadecf4fac4ee;p=stockfish diff --git a/src/bitboard.h b/src/bitboard.h index b99cc259..35904377 100644 --- a/src/bitboard.h +++ b/src/bitboard.h @@ -280,7 +280,7 @@ FORCE_INLINE Square msb(Bitboard b) { FORCE_INLINE Square pop_lsb(Bitboard* b) { const Square s = lsb(*b); - *b &= ~(1ULL << s); + *b &= *b - 1; return s; }