Any hand from any round mode has a chance of footstooling another hand from that same mode. This trait (Hand) allows us to implement these semantics (as well as any other shared semantics) for each round mode.
14 lines
209 B
Rust
14 lines
209 B
Rust
mod pair;
|
|
mod single;
|
|
|
|
#[derive(Eq, Ord, PartialEq, PartialOrd, Debug, Copy, Clone)]
|
|
pub enum Footstool {
|
|
None,
|
|
Half,
|
|
Full,
|
|
}
|
|
|
|
pub trait Hand {
|
|
fn footstool(&self, other: Self) -> Footstool;
|
|
}
|