projects
/
ghc-hetmet.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
External Core tools: track new syntax for newtypes
[ghc-hetmet.git]
/
utils
/
ext-core
/
ParsecParser.hs
diff --git
a/utils/ext-core/ParsecParser.hs
b/utils/ext-core/ParsecParser.hs
index
ab0d284
..
41a18a5
100644
(file)
--- a/
utils/ext-core/ParsecParser.hs
+++ b/
utils/ext-core/ParsecParser.hs
@@
-141,12
+141,10
@@
coreCdef = do
tys <- sepBy coreAtySaturated whiteSpace
return $ Constr dataConName tBinds tys
tys <- sepBy coreAtySaturated whiteSpace
return $ Constr dataConName tBinds tys
-coreTRep :: Parser (Maybe Ty)
+coreTRep :: Parser Ty
-- note that the "=" is inside here since if there's
-- no rhs for the newtype, there's no "="
-- note that the "=" is inside here since if there's
-- no rhs for the newtype, there's no "="
-coreTRep = optionMaybe (do
- symbol "="
- try coreType)
+coreTRep = symbol "=" >> try coreType
coreType :: Parser Ty
coreType = coreForallTy <|> (do
coreType :: Parser Ty
coreType = coreForallTy <|> (do