[board] Rename PiecePlacementError::PieceExistsOnSquare → ExistsOnSquare
This commit is contained in:
parent
80b78a8fef
commit
1575c83d31
2 changed files with 2 additions and 2 deletions
|
@ -47,7 +47,7 @@ impl Shape {
|
||||||
|
|
||||||
#[derive(Debug, Eq, PartialEq)]
|
#[derive(Debug, Eq, PartialEq)]
|
||||||
pub enum PiecePlacementError {
|
pub enum PiecePlacementError {
|
||||||
PieceExistsOnSquare,
|
ExistsOnSquare,
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
|
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
|
||||||
|
|
|
@ -76,7 +76,7 @@ impl Position {
|
||||||
let bitboard = self.bitboard_for_piece_mut(piece);
|
let bitboard = self.bitboard_for_piece_mut(piece);
|
||||||
|
|
||||||
if bitboard.has_piece_at(&square) {
|
if bitboard.has_piece_at(&square) {
|
||||||
return Err(PiecePlacementError::PieceExistsOnSquare);
|
return Err(PiecePlacementError::ExistsOnSquare);
|
||||||
}
|
}
|
||||||
|
|
||||||
bitboard.place_piece_at(&square);
|
bitboard.place_piece_at(&square);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue