Hi Paul, 2008/3/27 Paul Keir <[EMAIL PROTECTED]>: > Hi, > > Does anyone know why this reduced Parsec production stops compilation, and > how I can fix it? > > tester = reserved "parameter" > <|> do { reserved "dimension"; symbol ":" }
Look at the types of "reserved" and "symbol" (from http://www.haskell.org/ghc/docs/latest/html/libraries/parsec/Text-ParserCombinators-Parsec-Token.html): symbol :: String -> CharParser st String reserved :: String -> CharParser st () The type of a do block is the same as the type of its last statement. But (reserved "parameter") and (symbol ";") do not have the same type. Luke _______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe