From 5337edfdb6c9593e224be58225907682903db1a9 Mon Sep 17 00:00:00 2001 From: Shawn Xu Date: Sat, 31 May 2025 18:24:19 -0700 Subject: [PATCH] remove non-functional else since we break out of the loop in the other branch closes https://github.com/official-stockfish/Stockfish/pull/6116 no functional change --- src/search.cpp | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/src/search.cpp b/src/search.cpp index ddc27156..9f44defb 100644 --- a/src/search.cpp +++ b/src/search.cpp @@ -1380,15 +1380,13 @@ moves_loop: // When in check, search starts here assert(value >= beta); // Fail high break; } - else - { - // Reduce other moves if we have found at least one score improvement - if (depth > 2 && depth < 16 && !is_decisive(value)) - depth -= 2; - assert(depth > 0); - alpha = value; // Update alpha! Always alpha < beta - } + // Reduce other moves if we have found at least one score improvement + if (depth > 2 && depth < 16 && !is_decisive(value)) + depth -= 2; + + assert(depth > 0); + alpha = value; // Update alpha! Always alpha < beta } }