board backing referencing improvements
This commit is contained in:
@@ -5,7 +5,6 @@ use super::{
|
||||
};
|
||||
use static_assertions::const_assert;
|
||||
|
||||
#[cfg(not(feature = "bitvec"))]
|
||||
pub type BitBoardInner = u64;
|
||||
|
||||
#[derive(Copy, Clone, PartialEq, Eq)]
|
||||
@@ -42,6 +41,10 @@ impl BitBoard {
|
||||
self.0.count_ones() as usize
|
||||
}
|
||||
|
||||
pub const fn is_empty(&self) -> bool {
|
||||
self.0 == 0
|
||||
}
|
||||
|
||||
// Directional shifts with edge masking (prevents wrapping)
|
||||
pub const fn east(&self) -> Self {
|
||||
let mask = !Self::col_mask(Board::BOARD_SIZE - 1).0; // Mask to block column 7 bits
|
||||
|
||||
Reference in New Issue
Block a user