From: Marco Costalba Date: Tue, 29 Jun 2010 11:05:19 +0000 (+0200) Subject: Remove a redundant check in passed pawn eval X-Git-Url: https://git.sesse.net/?p=stockfish;a=commitdiff_plain;h=4d170725ab0ea2d219ff402495a1c541e7f75d6c Remove a redundant check in passed pawn eval When first condition is met then second one is always true. Spotted by Ralph Stoesser. No functional change. Signed-off-by: Marco Costalba --- diff --git a/src/evaluate.cpp b/src/evaluate.cpp index d291e46b..7fd0db57 100644 --- a/src/evaluate.cpp +++ b/src/evaluate.cpp @@ -861,8 +861,7 @@ namespace { // value if the other side has a rook or queen. if (square_file(s) == FILE_A || square_file(s) == FILE_H) { - if ( pos.non_pawn_material(Them) <= KnightValueMidgame - && pos.piece_count(Them, KNIGHT) <= 1) + if (pos.non_pawn_material(Them) <= KnightValueMidgame) ebonus += ebonus / 4; else if (pos.pieces(ROOK, QUEEN, Them)) ebonus -= ebonus / 4;