[Haskell-beginners] ($) operator

John Hartnup john.hartnup at gmail.com
Sat Jan 24 14:37:29 EST 2009


I'm working through Real World Haskell, and although it's going well
(I just finished the exercise to write a glob matcher without using a
regex library, and I'm pleased as punch), I keep seeing the ($)
operator, and I'm not sure I understand its use. If the book explains
it, I've been unable to find it.

Empirically, it seems like:
a $ b c d e f
.. is equivalent to ..
a (b c d e f)

But is that it's only purpose? To placate the LISP haters by removing

(1 +) 2  does the same thing as (1 +) $ 2, and has the same type.

Am I missing something?


"There is no way to peace; peace is the way"

More information about the Beginners mailing list