[MLton-user] Fixpoints
Vesa Karvonen
vesa.karvonen@cs.helsinki.fi
Mon, 7 Aug 2006 11:22:34 +0300
Quoting Henry Cejtin <henry.cejtin@sbcglobal.net>:
[...]
> Connected to this is one of my peeves with ML syntax: the fact that
> application associates to the left. Clearly this was done to curry (BAD BAD
> pun) favor from the people who use curried arguments, but the VAST majority
> of the time I want to apply a function to the result of a function
> application, not apply the result of a function to a variable.
In Haskell, the $ operator can sometimes help with that, see
http://haskell.org/ghc/docs/latest/html/libraries/base/Prelude.html#v%3A%24 .
See also "Application and piping operators" on http://mlton.org/InfixingOperators.
Personally, I'd use those operators more (in ML code that I post), but since
they are non-standard, there is a large overhead to communicate them, and so
I usually just grind my teeth and write ad hoc lambdas and extra parentheses.
-Vesa Karvonen