&& !pos.can_castle(ANY_CASTLING))
{
StateInfo st;
- ASSERT_ALIGNED(&st, Eval::NNUE::kCacheLineSize);
+ ASSERT_ALIGNED(&st, Eval::NNUE::CacheLineSize);
Position p;
p.set(pos.fen(), pos.is_chess960(), &st, pos.this_thread());
}
-/// Position::do(undo)_null_move() is used to do(undo) a "null move": it flips
+/// Position::do_null_move() is used to do a "null move": it flips
/// the side to move without executing any move on the board.
void Position::do_null_move(StateInfo& newSt) {
assert(pos_is_ok());
}
+
+/// Position::undo_null_move() must be used to undo a "null move"
+
void Position::undo_null_move() {
assert(!checkers());
if (!(stmAttackers = attackers & pieces(stm)))
break;
- // Don't allow pinned pieces to attack (except the king) as long as
- // there are pinners on their original square.
+ // Don't allow pinned pieces to attack as long as there are
+ // pinners on their original square.
if (pinners(~stm) & occupied)
stmAttackers &= ~blockers_for_king(stm);
assert(0 && "pos_is_ok: Bitboards");
StateInfo si = *st;
- ASSERT_ALIGNED(&si, Eval::NNUE::kCacheLineSize);
+ ASSERT_ALIGNED(&si, Eval::NNUE::CacheLineSize);
set_state(&si);
if (std::memcmp(&si, st, sizeof(StateInfo)))