fix the parsing for source commands

This commit is contained in:
Krasimir Angelov
2024-02-08 13:38:45 +01:00
parent 9fd1c5da80
commit ab30f1f9e5
3 changed files with 17 additions and 25 deletions

View File

@@ -28,7 +28,7 @@ pCommand = (do
cmd <- pIdent <++ (char '%' >> fmap ('%':) pIdent)
skipSpaces
opts <- sepBy pOption skipSpaces
arg <- if getCommandOp cmd == "cc" then pArgTerm else pArgument
arg <- if getCommandOp cmd `elem` ["cc","sd","so"] then pArgTerm else pArgument
return (Command cmd opts arg)
)
<++ (do