[Haskell-cafe] why can't you surround (+) in backticks and have it
be infix?
tphyahoo
tphyahoo at gmail.com
Mon Jan 8 10:03:09 EST 2007
"Issues: In Haskell, any function or constructor can be enclosed in backticks
and then used as an infix operator. "
from http://www-users.cs.york.ac.uk/~mfn/hacle/issues/node2.html
But this seems to be contradicted by...
from #haskell
-- 09:19 < tphyahoo> > let func = (+) in 1 `func` 2
-- 09:19 < lambdabot> 3
-- 09:20 < tphyahoo> but ......
-- 09:20 < tphyahoo> 1 `(+)` 2
-- 09:20 < tphyahoo> > 1 `(+)` 2
-- 09:20 < lambdabot> Parse error
(+) is a function, is it not?
Where's the rub?
thomas.
--
View this message in context: http://www.nabble.com/why-can%27t-you-surround-%28%2B%29-in-backticks-and-have-it-be-infix--tf2939834.html#a8219424
Sent from the Haskell - Haskell-Cafe mailing list archive at Nabble.com.
More information about the Haskell-Cafe
mailing list