ContentsIndex
Parse
Portabilityghc (undecidable and overlapping instances)
MaintainerMisha Aizatulin <avatar@hot.ee>
Description
Parse is a clone of Read. The reason we introduce a new class is to create new instances for some library datatypes that already have a Read instance.
Synopsis
class Parse a where
parsePrec :: ReadPrec a
parseListPrec :: ReadPrec [a]
data ParseInterface = forall a . (Typeable a, Parse a) => ParseInterface a
parse :: Parse a => String -> a
parseEither :: Parse a => String -> Either String a
Documentation
class Parse a where
Methods
parsePrec :: ReadPrec a
parseListPrec :: ReadPrec [a]
show/hide Instances
Parse Condition
Parse RuleArg
Parse ()
(Parse a, Parse b) => Parse (a, b)
(Parse a, Parse b, Parse c) => Parse (a, b, c)
(Parse a, Parse b, Parse c, Parse d) => Parse (a, b, c, d)
(Parse a, Parse b, Parse c, Parse d, Parse e) => Parse (a, b, c, d, e)
Read a => Parse a
(Ord a, Parse a) => Parse (Set a)
Parse a => Parse [a]
(Ord k, Parse k, Parse e) => Parse (Map k e)
data ParseInterface
Constructors
forall a . (Typeable a, Parse a) => ParseInterface a
show/hide Instances
Typeable a => Typeable ParseInterface
parse :: Parse a => String -> a
Gives an error if there isn't a unique parse.
parseEither :: Parse a => String -> Either String a
Produced by Haddock version 0.8