Skip to content

Commit

Permalink
Merge pull request #3 from Coda-Coda/fix-extra-brace
Browse files Browse the repository at this point in the history
Fix extra `}` generated when `ret ++ fargs` is empty
  • Loading branch information
jkopanski authored Oct 8, 2024
2 parents 24aad3a + 4b51900 commit a8862bf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion vc/src/Main.hs
Original file line number Diff line number Diff line change
Expand Up @@ -259,7 +259,7 @@ fillInFunction topLevelContract file imports (FuncDef _ contract fargs ret body)
funcArgs = generateGuarded (null fargs) $ "(" ++ unwords fargs ++ " : Literal)"
opens = opensOfImports topLevelContract imports
retVals = generateGuarded (null ret) $ "(" ++ unwords ret ++ " : Identifier)"
rValsAndArgs = generateGuarded (null (ret ++ fargs)) "{" ++ unwords ret ++ " " ++ argsSepSpace ++ "}"
rValsAndArgs = generateGuarded (null (ret ++ fargs)) $ "{" ++ unwords ret ++ " " ++ argsSepSpace ++ "}"
replaceIn ttype =
replaceMany [
("\\<imports>", leanImports ++ internalImports topLevelContract contract file ttype),
Expand Down

0 comments on commit a8862bf

Please sign in to comment.