Add 'FromFen' trait
This commit is contained in:
parent
de27c186d3
commit
0fd9766db0
6
src/fen.rs
Normal file
6
src/fen.rs
Normal file
|
@ -0,0 +1,6 @@
|
|||
/// A trait to mark items that can be converted from a FEN input.
|
||||
pub trait FromFen: Sized {
|
||||
type Err;
|
||||
|
||||
fn from_fen(s: &str) -> Result<Self, Self::Err>;
|
||||
}
|
|
@ -1,3 +1,4 @@
|
|||
pub mod board;
|
||||
pub mod fen;
|
||||
pub mod movegen;
|
||||
pub mod utils;
|
||||
|
|
Loading…
Reference in a new issue