[board] Move piece! and position! macros to a new macros.rs module

This commit is contained in:
Eryn Wells 2024-01-19 17:51:57 -08:00
parent e56b3259e2
commit 2269df2ed9
5 changed files with 22 additions and 21 deletions

View file

@ -18,15 +18,6 @@ pub(crate) enum BoardSide {
Queen,
}
#[macro_export]
macro_rules! position {
[$($color:ident $shape:ident on $square:ident,)*] => {
$crate::Position::from_iter([
$($crate::piece!($color $shape on $square)),*
].into_iter())
};
}
#[derive(Clone, Eq, PartialEq)]
pub struct Position {
color_to_move: Color,