Retire Position::in_check()

It is redundant with Position::checkers()

No functional change.
This commit is contained in:
Marco Costalba
2012-12-25 17:59:35 +01:00
parent 3b49aeb4f2
commit e82382703c
7 changed files with 17 additions and 22 deletions

View File

@@ -361,7 +361,7 @@ namespace {
template<bool Trace>
Value do_evaluate(const Position& pos, Value& margin) {
assert(!pos.in_check());
assert(!pos.checkers());
EvalInfo ei;
Score score, mobilityWhite, mobilityBlack;
@@ -1014,7 +1014,7 @@ Value do_evaluate(const Position& pos, Value& margin) {
// Opponent king cannot block because path is defended and position
// is not in check. So only friendly pieces can be blockers.
assert(!pos.in_check());
assert(!pos.checkers());
assert((queeningPath & pos.pieces()) == (queeningPath & pos.pieces(c)));
// Add moves needed to free the path from friendly pieces and retest condition