| ... | ... | @@ -127,7 +127,8 @@ replace: |
|
|
|
|
|
|
|
|
|
|
|
with:
|
|
|
|
"The handling of the prefix negation operator, -, complicates matters only slightly. (Recall that) prefix negation has lower precedence than infix multiplication. The operator to the left of prefix -, if there is one, is ignored. So a + -b or a \* -b are legal. Prefix negation binds tighter with infix operators to the right of lower precedence than multiplication. So for example -a + b is legal and resolves as (-a) + b."
|
|
|
|
"The handling of the prefix negation operator, -, complicates matters only slightly. (Recall that) prefix negation has lower precedence than infix multiplication. So -a \* b resolves as -(a \* b) or more importantly `-a ^ b` as `-(a ^ b)`. Generally, prefix negation extends as long to the right as there are consecutive infix operators with precedences at least as high as multiplication.
|
|
|
|
The operator to the left of prefix -, if there is one, is ignored. So a + -b or a \* -b are legal. Prefix negation binds tighter with infix operators to the right of lower precedence than multiplication. So for example -a + b is legal and resolves as (-a) + b."
|
|
|
|
|
|
|
|
|
|
|
|
(Use may algorithm from [ http://hackage.haskell.org/trac/ghc/ticket/4180](http://hackage.haskell.org/trac/ghc/ticket/4180)) |
|
|
|
(Use the algorithm from [ http://hackage.haskell.org/trac/ghc/ticket/4180](http://hackage.haskell.org/trac/ghc/ticket/4180)) |