mirror of
https://github.com/HChaZZY/Stockfish.git
synced 2025-12-25 03:26:24 +08:00
Fix very theoretical History corner case
Signed-off-by: Marco Costalba <mcostalba@gmail.com>
This commit is contained in:
committed by
Marco Costalba
parent
842efefcad
commit
998845763a
@@ -62,7 +62,7 @@ inline Value History::value(Piece p, Square to) const {
|
||||
}
|
||||
|
||||
inline void History::update(Piece p, Square to, Value bonus) {
|
||||
if (abs(history[p][to]) < MaxValue) history[p][to] += bonus;
|
||||
if (abs(history[p][to] + bonus) < MaxValue) history[p][to] += bonus;
|
||||
}
|
||||
|
||||
inline Value History::gain(Piece p, Square to) const {
|
||||
|
||||
Reference in New Issue
Block a user