clippy
This commit is contained in:
parent
27e936c22a
commit
eb224adec3
@ -34,7 +34,7 @@ pub struct Board {
|
|||||||
impl fmt::Display for Board {
|
impl fmt::Display for Board {
|
||||||
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result {
|
||||||
for i in 0..BOARD_SIZE {
|
for i in 0..BOARD_SIZE {
|
||||||
write!(f, "{}\n", "-".repeat(BOARD_SIZE * 2 + 1))?;
|
writeln!(f, "{}", "-".repeat(BOARD_SIZE * 2 + 1))?;
|
||||||
|
|
||||||
write!(f, "|")?;
|
write!(f, "|")?;
|
||||||
for j in 0..BOARD_SIZE {
|
for j in 0..BOARD_SIZE {
|
||||||
@ -44,7 +44,7 @@ impl fmt::Display for Board {
|
|||||||
self.get(i, j).as_ref().map(Piece::text).unwrap_or(" ")
|
self.get(i, j).as_ref().map(Piece::text).unwrap_or(" ")
|
||||||
)?;
|
)?;
|
||||||
}
|
}
|
||||||
write!(f, "\n")?;
|
writeln!(f)?;
|
||||||
}
|
}
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user