Safe Haskell | None |
---|---|
Language | Haskell2010 |
- class DF d where
- parseF :: (DF d, CharParsing p) => p d
Documentation
parseF :: (DF d, CharParsing p) => p d Source #
>>>
parse (parseF <* eof) "test" "F" :: Either ParseError Digit
Right F
>>>
parse parseF "test" "Fxyz" :: Either ParseError Digit
Right F
>>>
isn't _Right (parse parseF "test" "xyz" :: Either ParseError Digit)
True
\c -> c /= 'F' ==> isn't _Right (parse parseF "test" [c] :: Either ParseError Digit)