Copyright | (c) Mario Lang 2021 |
---|---|
License | BSD3 |
Maintainer | mlang@blind.guru |
Stability | experimental |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
Parsers and printers for Algebraic Notation.
Synopsis
- fromSAN :: (VisualStream s, TraversableStream s, SANToken (Token s), IsString (Tokens s)) => Position -> s -> Either String Ply
- toSAN :: (HasCallStack, IsString s) => Position -> Ply -> s
- unsafeToSAN :: Position -> Ply -> String
- class SANToken a
- strictSAN :: forall s. (Stream s, SANToken (Token s), IsString (Tokens s)) => Position -> Parser s Ply
- relaxedSAN :: (Stream s, SANToken (Token s), IsString (Tokens s)) => Position -> Parser s Ply
- varToSAN :: (MonoFoldable variation, Element variation ~ Ply, IsString string) => Position -> variation -> string
Conversion
fromSAN :: (VisualStream s, TraversableStream s, SANToken (Token s), IsString (Tokens s)) => Position -> s -> Either String Ply Source #
Parsers
sanPieceToken, fileToken, rankToken, promotionPieceToken, statusToken
Instances
SANToken Word8 Source # | |
Defined in Game.Chess.SAN | |
SANToken Char Source # | |
Defined in Game.Chess.SAN |
strictSAN :: forall s. (Stream s, SANToken (Token s), IsString (Tokens s)) => Position -> Parser s Ply Source #
relaxedSAN :: (Stream s, SANToken (Token s), IsString (Tokens s)) => Position -> Parser s Ply Source #