Trait littlewing::bitboard::BitboardExt
[−]
[src]
pub trait BitboardExt { fn count(&self) -> u32; fn scan(&self) -> u32; fn shift(&self, x: i8) -> Bitboard; fn toggle(&mut self, i: Square); fn set(&mut self, i: Square); fn reset(&mut self, i: Square); fn get(&self, i: Square) -> bool; fn debug(&self); fn to_debug_string(&self) -> String; }
Required Methods
fn count(&self) -> u32
Population count using LLVM ctpop
fn scan(&self) -> u32
Bitscan using LLVM cttz
fn shift(&self, x: i8) -> Bitboard
Left shift positive values or right shift negative values
fn toggle(&mut self, i: Square)
Toggle occupancy bit at the given square
fn set(&mut self, i: Square)
Set occupancy bit at the given square
fn reset(&mut self, i: Square)
Reset occupancy bit at the given square
fn get(&self, i: Square) -> bool
Get occupancy at the given square
fn debug(&self)
fn to_debug_string(&self) -> String
Implementors
impl BitboardExt for Bitboard