Safe Haskell | None |
---|---|
Language | Haskell2010 |
- decode :: ByteString -> Either String Sexp
- decodeMany :: ByteString -> Either String [Sexp]
- encode :: Sexp -> ByteString
- format :: Sexp -> ByteString
- type Sexp = Fix SexpF
- pattern Atom :: Atom -> Sexp
- pattern Number :: Scientific -> Sexp
- pattern Symbol :: Text -> Sexp
- pattern String :: Text -> Sexp
- pattern ParenList :: [Sexp] -> Sexp
- pattern BracketList :: [Sexp] -> Sexp
- pattern BraceList :: [Sexp] -> Sexp
- pattern Modified :: Prefix -> Sexp -> Sexp
- data SexpF e
- = AtomF !Atom
- | ParenListF [e]
- | BracketListF [e]
- | BraceListF [e]
- | ModifiedF !Prefix e
- data Atom
- = AtomNumber !Scientific
- | AtomString !Text
- | AtomSymbol !Text
- data Prefix
Parse and print
decodeMany :: ByteString -> Either String [Sexp] Source #
Deserialise potentially multiple Sexp
from a string
Type
pattern Number :: Scientific -> Sexp Source #
pattern BracketList :: [Sexp] -> Sexp Source #
Internal types
S-expression functor
AtomF !Atom | |
ParenListF [e] | |
BracketListF [e] | |
BraceListF [e] | |
ModifiedF !Prefix e |
S-expression atom type
S-expression quotation type