[board] Remove explicit #[inline] from several Board methods
Trust the compiler to inline where appropriate, until I know otherwise.
This commit is contained in:
parent
7a46d52e8d
commit
26ae79e17d
1 changed files with 0 additions and 5 deletions
|
@ -107,25 +107,21 @@ impl Board {
|
||||||
}
|
}
|
||||||
|
|
||||||
/// A [`BitBoard`] representing the set of squares containing a piece.
|
/// A [`BitBoard`] representing the set of squares containing a piece.
|
||||||
#[inline]
|
|
||||||
#[must_use]
|
#[must_use]
|
||||||
pub fn occupied_squares(&self) -> &BitBoard {
|
pub fn occupied_squares(&self) -> &BitBoard {
|
||||||
self.pieces.all_pieces()
|
self.pieces.all_pieces()
|
||||||
}
|
}
|
||||||
|
|
||||||
#[inline]
|
|
||||||
#[must_use]
|
#[must_use]
|
||||||
pub fn friendly_pieces(&self) -> &BitBoard {
|
pub fn friendly_pieces(&self) -> &BitBoard {
|
||||||
self.pieces.all_pieces_of_color(self.player_to_move)
|
self.pieces.all_pieces_of_color(self.player_to_move)
|
||||||
}
|
}
|
||||||
|
|
||||||
#[inline]
|
|
||||||
#[must_use]
|
#[must_use]
|
||||||
pub fn opposing_pieces(&self) -> &BitBoard {
|
pub fn opposing_pieces(&self) -> &BitBoard {
|
||||||
self.pieces.all_pieces_of_color(self.player_to_move.other())
|
self.pieces.all_pieces_of_color(self.player_to_move.other())
|
||||||
}
|
}
|
||||||
|
|
||||||
#[inline]
|
|
||||||
#[must_use]
|
#[must_use]
|
||||||
pub fn all_pieces(&self) -> (&BitBoard, &BitBoard) {
|
pub fn all_pieces(&self) -> (&BitBoard, &BitBoard) {
|
||||||
(self.friendly_pieces(), self.opposing_pieces())
|
(self.friendly_pieces(), self.opposing_pieces())
|
||||||
|
@ -133,7 +129,6 @@ impl Board {
|
||||||
|
|
||||||
/// A [`BitBoard`] representing the set of squares containing a piece. This set is the inverse of
|
/// A [`BitBoard`] representing the set of squares containing a piece. This set is the inverse of
|
||||||
/// `Board::occupied_squares`.
|
/// `Board::occupied_squares`.
|
||||||
#[inline]
|
|
||||||
#[must_use]
|
#[must_use]
|
||||||
pub fn empty_squares(&self) -> BitBoard {
|
pub fn empty_squares(&self) -> BitBoard {
|
||||||
!self.occupied_squares()
|
!self.occupied_squares()
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue