[position] Fix a few warnings related to imports; make position::Flags public
This commit is contained in:
parent
52b19b87d8
commit
8aa44e56f2
5 changed files with 7 additions and 9 deletions
|
@ -4,7 +4,7 @@
|
||||||
//! generating the possible moves for the king in the given position.
|
//! generating the possible moves for the king in the given position.
|
||||||
|
|
||||||
use super::{move_generator_declaration, MoveGeneratorInternal, MoveSet};
|
use super::{move_generator_declaration, MoveGeneratorInternal, MoveSet};
|
||||||
use crate::{r#move::Castle, Move, MoveBuilder, Position};
|
use crate::{r#move::Castle, Position};
|
||||||
use chessfriend_bitboard::BitBoard;
|
use chessfriend_bitboard::BitBoard;
|
||||||
use chessfriend_core::{Color, Piece, PlacedPiece};
|
use chessfriend_core::{Color, Piece, PlacedPiece};
|
||||||
|
|
||||||
|
@ -52,7 +52,7 @@ impl MoveGeneratorInternal for KingMoveGenerator {
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
mod tests {
|
mod tests {
|
||||||
use super::*;
|
use super::*;
|
||||||
use crate::{assert_move_list, position, test_position, PositionBuilder};
|
use crate::{assert_move_list, position, test_position, Move, MoveBuilder, PositionBuilder};
|
||||||
use chessfriend_bitboard::bitboard;
|
use chessfriend_bitboard::bitboard;
|
||||||
use chessfriend_core::{piece, Square};
|
use chessfriend_core::{piece, Square};
|
||||||
use std::collections::HashSet;
|
use std::collections::HashSet;
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
// Eryn Wells <eryn@erynwells.me>
|
// Eryn Wells <eryn@erynwells.me>
|
||||||
|
|
||||||
use super::{move_generator_declaration, MoveGeneratorInternal, MoveSet};
|
use super::{move_generator_declaration, MoveGeneratorInternal, MoveSet};
|
||||||
use crate::{MoveBuilder, Position};
|
use crate::Position;
|
||||||
use chessfriend_bitboard::BitBoard;
|
use chessfriend_bitboard::BitBoard;
|
||||||
use chessfriend_core::{Color, Piece, PlacedPiece};
|
use chessfriend_core::{Color, Piece, PlacedPiece};
|
||||||
|
|
||||||
|
@ -29,7 +29,7 @@ impl MoveGeneratorInternal for KnightMoveGenerator {
|
||||||
#[cfg(test)]
|
#[cfg(test)]
|
||||||
mod tests {
|
mod tests {
|
||||||
use super::*;
|
use super::*;
|
||||||
use crate::{position, Move};
|
use crate::{position, Move, MoveBuilder};
|
||||||
use chessfriend_core::{piece, Square};
|
use chessfriend_core::{piece, Square};
|
||||||
use std::collections::HashSet;
|
use std::collections::HashSet;
|
||||||
|
|
||||||
|
|
|
@ -1,8 +1,6 @@
|
||||||
// Eryn Wells <eryn@erynwells.me>
|
// Eryn Wells <eryn@erynwells.me>
|
||||||
|
|
||||||
use crate::{
|
use crate::{position::flags::Flags, r#move::Castle, MakeMoveError, Move, Position};
|
||||||
position::flags::Flags, r#move::Castle, sight::SightExt, MakeMoveError, Move, Position,
|
|
||||||
};
|
|
||||||
use chessfriend_bitboard::BitBoard;
|
use chessfriend_bitboard::BitBoard;
|
||||||
use chessfriend_core::{Color, Direction, Piece, PlacedPiece, Shape, Square};
|
use chessfriend_core::{Color, Direction, Piece, PlacedPiece, Shape, Square};
|
||||||
|
|
||||||
|
|
|
@ -3,7 +3,7 @@
|
||||||
use crate::{
|
use crate::{
|
||||||
position::{flags::Flags, piece_sets::PieceBitBoards},
|
position::{flags::Flags, piece_sets::PieceBitBoards},
|
||||||
r#move::Castle,
|
r#move::Castle,
|
||||||
MakeMoveError, Move, Position,
|
Position,
|
||||||
};
|
};
|
||||||
use chessfriend_core::{piece, Color, Piece, PlacedPiece, Rank, Shape, Square};
|
use chessfriend_core::{piece, Color, Piece, PlacedPiece, Rank, Shape, Square};
|
||||||
use std::collections::BTreeMap;
|
use std::collections::BTreeMap;
|
||||||
|
|
|
@ -5,7 +5,7 @@ use chessfriend_core::Color;
|
||||||
use std::fmt;
|
use std::fmt;
|
||||||
|
|
||||||
#[derive(Clone, Copy, Eq, Hash, PartialEq)]
|
#[derive(Clone, Copy, Eq, Hash, PartialEq)]
|
||||||
pub(super) struct Flags(u8);
|
pub struct Flags(u8);
|
||||||
|
|
||||||
impl Flags {
|
impl Flags {
|
||||||
#[inline]
|
#[inline]
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue