Created
June 25, 2010 21:27
-
-
Save billdozr/453468 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
lexer = T.makeTokenParser L.emptyDef | |
lexeme = T.lexeme lexer | |
parens = T.parens lexer | |
comma = T.comma lexer | |
colon = T.colon lexer | |
float = T.float lexer | |
symbol = T.symbol lexer | |
whiteSpace = T.whiteSpace lexer | |
-- Parser(s) | |
commandParser = Command | |
<$> (char '@' *> many alphaNum) | |
<*> optional (parens (many alphaNum `sepBy` comma)) | |
<*> (colon *> (many (noneOf ":\n") `sepBy` symbol "::")) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment