1
0
Fork 0
mirror of https://github.com/sockspls/badfish synced 2025-04-30 16:53:09 +00:00

Remove redundant if-statements

No functional change

Closes #1173
This commit is contained in:
VoyagerOne 2017-07-27 02:14:18 -07:00 committed by Joona Kiiski
parent 973ede008a
commit 722e1e0da6

View file

@ -682,8 +682,8 @@ namespace {
eval = ss->staticEval = evaluate(pos); eval = ss->staticEval = evaluate(pos);
// Can ttValue be used as a better position evaluation? // Can ttValue be used as a better position evaluation?
if (ttValue != VALUE_NONE) if ( ttValue != VALUE_NONE
if (tte->bound() & (ttValue > eval ? BOUND_LOWER : BOUND_UPPER)) && (tte->bound() & (ttValue > eval ? BOUND_LOWER : BOUND_UPPER)))
eval = ttValue; eval = ttValue;
} }
else else
@ -1212,8 +1212,8 @@ moves_loop: // When in check search starts from here
ss->staticEval = bestValue = evaluate(pos); ss->staticEval = bestValue = evaluate(pos);
// Can ttValue be used as a better position evaluation? // Can ttValue be used as a better position evaluation?
if (ttValue != VALUE_NONE) if ( ttValue != VALUE_NONE
if (tte->bound() & (ttValue > bestValue ? BOUND_LOWER : BOUND_UPPER)) && (tte->bound() & (ttValue > bestValue ? BOUND_LOWER : BOUND_UPPER)))
bestValue = ttValue; bestValue = ttValue;
} }
else else