File tree Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Expand file tree Collapse file tree 1 file changed +12
-2
lines changed Original file line number Diff line number Diff line change @@ -308,14 +308,24 @@ useStatement = do
308
308
309
309
moduleSubprogramDeclaration :: ReadP LineContents
310
310
moduleSubprogramDeclaration = do
311
- skipAnything
311
+ skipSpaces
312
+ skipProcedureQualifiers
312
313
_ <- string " module"
313
314
skipAtLeastOneWhiteSpace
314
- skipAnything
315
315
_ <- string " function" <|> string " subroutine"
316
316
skipAtLeastOneWhiteSpace
317
317
return $ ModuleSubprogramDeclaration
318
318
319
+ skipProcedureQualifiers :: ReadP ()
320
+ skipProcedureQualifiers = do
321
+ many skipPossibleQualifier
322
+ return ()
323
+
324
+ skipPossibleQualifier :: ReadP ()
325
+ skipPossibleQualifier = do
326
+ _ <- string " pure" <|> string " elemental" <|> string " impure"
327
+ skipAtLeastOneWhiteSpace
328
+
319
329
skipAtLeastOneWhiteSpace :: ReadP ()
320
330
skipAtLeastOneWhiteSpace = do
321
331
_ <- many1 whiteSpace
You can’t perform that action at this time.
0 commit comments