Refactor some clippy-pedantic errors

This commit is contained in:
stefiosif
2024-09-06 20:30:57 +03:00
parent 6b9650a6f0
commit 2093d91dfa
12 changed files with 42 additions and 47 deletions

View File

@@ -27,12 +27,12 @@ pub fn quiescence(game: &mut Game, mut alpha: i32, beta: i32) -> (Option<Move>,
game.board.make_move(&mv);
if game.board.king_under_check(color) {
game.board.unmake_move(move_parameters);
game.board.unmake_move(&move_parameters);
continue;
}
let move_score = -quiescence(game, -beta, -alpha).1;
game.board.unmake_move(move_parameters);
game.board.unmake_move(&move_parameters);
if move_score >= beta {
return (Some(mv), beta);