[Haskell-cafe] Proposal: Infix expression keyword: -XInfixExpressions
Vo Minh Thu
noteed at gmail.com
Thu Feb 19 15:07:26 UTC 2015
infix <op> a b c d → a <op> b <op> c <op> d
makes me thing to the Lisp (+ a b c d) s-expression...
And indeed your infix keyword could be replaced by something like
⟨<op> a b c d⟩ → a <op> b <op> c <op> d
Voilà, s-expressions part of Haskell syntax !
2015-02-19 15:51 GMT+01:00 Christopher Done <chrisdone at gmail.com>:
> The idiom discussion brought back to mind a general problem (well, for
> me) in Haskell syntax which is there is no syntactic sugar for
> interspersing operators to many arguments.
> Regarding a solution for this, I wrote up a wee proposal here:
> If I go ahead and implement this in GHC as -XInfixExpressions or
> something (better names welcome), would it be likely to be accepted? I
> could first do an implementation in haskell-src-exts to demonstrate
> the concept.
> Haskell-Cafe mailing list
> Haskell-Cafe at haskell.org
More information about the Haskell-Cafe