Move the Perft trait into the position crate, and let the perft binary call into that. Amend Position::make_move to return a bool in the Ok case that indicates whether the position has been seen before. Use this to decide whether to continue recursing during the Perft run. I haven't seen that this makes a difference in the counts returned by Perft yet.
14 lines
279 B
Rust
14 lines
279 B
Rust
// Eryn Wells <eryn@erynwells.me>
|
|
|
|
mod position;
|
|
|
|
#[macro_use]
|
|
mod macros;
|
|
|
|
pub use chessfriend_board::{fen, PlacePieceError, PlacePieceStrategy};
|
|
pub use chessfriend_moves::{GeneratedMove, ValidateMove};
|
|
pub use position::Position;
|
|
|
|
pub mod perft;
|
|
#[macro_use]
|
|
pub mod testing;
|