[board] Derive Ord and PartialOrd on Square
This commit is contained in:
parent
7c2b9ed97a
commit
1689da9908
1 changed files with 1 additions and 1 deletions
|
@ -20,7 +20,7 @@ pub struct ParseSquareError;
|
||||||
#[derive(Debug)]
|
#[derive(Debug)]
|
||||||
pub struct SquareOutOfBoundsError;
|
pub struct SquareOutOfBoundsError;
|
||||||
|
|
||||||
#[derive(Clone, Copy, Debug, Eq, Hash, PartialEq)]
|
#[derive(Clone, Copy, Debug, Eq, Hash, Ord, PartialEq, PartialOrd)]
|
||||||
pub struct Square {
|
pub struct Square {
|
||||||
rank: u8,
|
rank: u8,
|
||||||
file: u8,
|
file: u8,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue