Wolfgang Jeltsch wolfgang@jeltsch.net
Wed, 8 Aug 2001 15:54:19 +0200

I totally agree with Gary. In my opinion the unary minus is a anomaly in 
Haskell which causes a lot of problems while beeing not that useful. For me 
it is totally okay to use negate x instead of -x.


Gary wrote:
> Hello people,
> I've been studying the Haskell 98 report as part of my study of the Haskell
> language and need to rant just a little bit.
> <micro-rant>
> As long as were trying to clean up a final version of the Haskell 98
> report, lets simplify it a little by getting rid of unary minus.
> It's the only prefix operator in the whole language.
> It requires messing up the otherwise clean expression syntax.
> It has a meaning that the user can't change, very rare in Haskell.
> It even has a fixed precedence level.
> It leads to excessive confusion when dealing with sections involving '-'
> (the binary operator).
> Uses can be replaced by either negate x or 0-x.
> </micro-rant>
> I know we can't actually remove unary minus at this point, I just had to
> get this off my chest.
> -- Gary