Anton van Straaten wrote:
Derek Elkins wrote:
> * A related annoyance is people who talk about languages "supporting
> currying and/or partial application."  Unless one means that the
> language supports higher order functions at all by that, it doesn't make
> any sense.  Haskell has no "support" for currying or partial
> application.  The fact that most functions are in curried form in
> Haskell is merely a convention (with, admittedly strong -social-
> ramifications.)  The only way one could say Haskell "supports" currying
> is that it has a lightweight notation for nested lambdas.

Compared to most other languages, that lightweight notation makes enough of a difference that it's reasonable to say that Haskell "supports currying and partial application".
[...]
Together, these two sugary treats make it quite a bit more convenient and practical to use currying and partial application in Haskell (and ML, etc.), and this translates to *much* more use in practice.

The lightweight syntax for definition and application helps tremendously. But another thing that helps a lot is that GHC is smart enough to make it efficient. OCaml also has fairly lightweight syntax compared to Java and Scheme, but the community is strongly focused on performance and they tend to get riled up about when and when-not to use it. Whereas Haskell nurtures a community that says "let the compiler do the ugly things", which is backed by excellent compiler writers. This perspective difference can also be seen in the let/letrec distinction vs letting the compiler figure it out.

--
Live well,
~wren
_______________________________________________
Haskell-Cafe mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/haskell-cafe

Reply via email to