@@ -60,14 +60,18 @@ moduleDecl =
60 expecting "a module declaration" $
60 expecting "a module declaration" $
62 tag <- parseTag
62 tag <- parseTag
64− names <- padded (dotSep1 capVar) <?> "the name of this module"
65+ names <- dotSep1 capVar <?> "the name of this module"
66 settings <- option Module.emptySettings parseSetting
68 settings <- option Module.emptySettings parseSetting
68− exports <- padded (listing (addLocation value))
71+ reserved "exposing"
70− reserved "where"
74+ exports <- listing (addLocation value)
72 return (ModuleDecl tag names exports settings)
76 return (ModuleDecl tag names exports settings)
@@ -99,11 +103,13 @@ parseTag =
100parseSetting :: IParser Module.SourceSettings
104parseSetting :: IParser Module.SourceSettings
101parseSetting =
105parseSetting =
106+ do try (reserved "where")
102− addLocation $ brackets $ commaSep $
108+ addLocation $ brackets $ commaSep $
103− do name <- addLocation lowVar
109+ do name <- addLocation lowVar
104− padded equals
110+ padded equals
105− typeName <- addLocation capVar
111+ typeName <- addLocation capVar
106− return (name, typeName)
112+ return (name, typeName)
109imports :: IParser [Module.UserImport]
115imports :: IParser [Module.UserImport]