on master help sign in
Doc comments go before options!
commit5f7fb9a123b9a92864bc950a734625779401e921 authorEdwin Brady <ecb10@st-andrews.ac.uk> dateSat 27 Feb 2016, 09:26 (11 years ago) parent12ec600
1 file changed+6−4
src/Idris/Parser.hs+6−4
src/Idris/Parser.hs+6−4
@@ -911,14 +911,16 @@ instance_ kwopt syn
911911 let initOpts = if default_total ist
912912 then [TotalFn]
913913 else []
914+
915+ (doc, argDocs) <- docstring syn
914916 opts <- fnOpts initOpts
915917 acc <- accessibility
916918 opts' <- fnOpts opts
919+
920+ if kwopt then optional instanceKeyword
921+ else do instanceKeyword
922+ return (Just ())
917923
918− (doc, argDocs)
919− <- try (docstring syn <* if kwopt then optional instanceKeyword
920− else do instanceKeyword
921− return (Just ()))
922924 fc <- getFC
923925 en <- optional instanceName
924926 cs <- constraintList syn