Skip to content

Commit

Permalink
in Formal.usePrec, removed variant parenthOpt for a better control of…
Browse files Browse the repository at this point in the history
… parentheses ; use Formal.parenth explicitly if you want to parse superfluous parentheses
  • Loading branch information
aarneranta committed Jul 29, 2024
1 parent 82075be commit 710e736
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/prelude/Formal.gf
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ resource Formal = open Prelude in {
usePrec : Prec -> TermPrec -> Str = \p,x ->
case lessPrec x.p p of {
True => parenth x.s ;
False => parenthOpt x.s
False => x.s --- parenthOpt x.s
} ;

parenth : Str -> Str = \s -> "(" ++ s ++ ")" ;
Expand Down

0 comments on commit 710e736

Please sign in to comment.