Skip to content

Commit

Permalink
slightly simplify sufficient_material
Browse files Browse the repository at this point in the history
  • Loading branch information
Icerath committed Jan 10, 2025
1 parent 29f4468 commit f6aaee4
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions src/core/board.rs
Original file line number Diff line number Diff line change
Expand Up @@ -279,12 +279,7 @@ impl Board {
let w = self.side_bitboards(White);
let b = self.side_bitboards(Black);

!w[Queen].is_empty()
|| !b[Queen].is_empty()
|| !w[Rook].is_empty()
|| !b[Rook].is_empty()
|| !w[Pawn].is_empty()
|| !b[Pawn].is_empty()
!(self[Queen] | self[Rook] | self[Pawn]).is_empty()
|| w[Bishop].count() >= 2
|| b[Bishop].count() >= 2
|| (!w[Bishop].is_empty() && !w[Knight].is_empty())
Expand Down

0 comments on commit f6aaee4

Please sign in to comment.