Enum shakmaty::EnPassantMode
source · pub enum EnPassantMode {
Legal,
PseudoLegal,
Always,
}
Expand description
When to include the en passant square.
Variants§
Legal
Only if there is a fully legal en passant move.
PseudoLegal
Only when a pawn has been advanced by two steps and there is an enemy pawn next to it.
Follows the X-FEN specification.
Always
Whenever a pawn has been advanced by two steps.
Follows the FEN specification.
Trait Implementations§
source§impl Clone for EnPassantMode
impl Clone for EnPassantMode
source§fn clone(&self) -> EnPassantMode
fn clone(&self) -> EnPassantMode
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for EnPassantMode
impl Debug for EnPassantMode
source§impl Hash for EnPassantMode
impl Hash for EnPassantMode
source§impl PartialEq for EnPassantMode
impl PartialEq for EnPassantMode
source§fn eq(&self, other: &EnPassantMode) -> bool
fn eq(&self, other: &EnPassantMode) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Copy for EnPassantMode
impl Eq for EnPassantMode
impl StructuralPartialEq for EnPassantMode
Auto Trait Implementations§
impl Freeze for EnPassantMode
impl RefUnwindSafe for EnPassantMode
impl Send for EnPassantMode
impl Sync for EnPassantMode
impl Unpin for EnPassantMode
impl UnwindSafe for EnPassantMode
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more