Live data from Hacker News

Can we stop calling it currying?

news.ycombinator.com

31–40 of 44 posts

Re: Can we stop calling it currying?

#31
post #5

Why call them 'arguments' when nobody is arguing? Currying is the name of the thing. Adding another Enterprise Edition Operational Process Development Pattern like "argument deferral" isn't any better. I mean "Dependency Injection" isn't any easier for beginners to grasp, even though that is what it is. Besides, it isn't argument deferral. That could easily be confused with evaluation order or things like lazy/normal…

From the perspective of a non-functional language, it is argument deferral because you're composing your sequence of functions first, which can then be used by later adding inputs for evaluation.

Were you thinking of partial application (not the same as currying)? I would agree that this is not argument deferral, rather it's more like argument presetting.

Re: Can we stop calling it currying?

#32
post #20

That's why Clojure calls it "partial" to indicate you're doing partial application http://conj.io/store/v0/org.clojure/clojure/1.7.0-alpha4/clj...

Again, your description refers to "partial application", which is different from currying. I think that many people are comfortable with "currying" only because they think it's the same as partial application. The fact that this is incorrect is good reason to revisit the term.

Re: Can we stop calling it currying?

#33
post #20

That's why Clojure calls it "partial" to indicate you're doing partial application http://conj.io/store/v0/org.clojure/clojure/1.7.0-alpha4/clj...

Partial application isn't currying; partially applying a function f to a first argument x is equivalent to currying f, applying the resulting unary function to x, and uncurrying the function that results from that application.

So, partial application can be defined in terms of currying, application, and uncurrying, but its not the same as currying.

Re: Can we stop calling it currying?

#34

Thanks everyone for the comments. It is interesting to see how widely "currying" is conflated with "partial application". I have to say, I still find the name to be a stumbling block. Perhaps this discussion can help to reverse that trend. I have also learned a good deal more from these comments and further research. It seems my idea of "currying" was not entirely complete. Per the comment herein: "Currying turns pol…

> To summarize, I'm submitting "sequencing" and "bundling" as the two simple verbs that better describe "currying" and "uncurrying".

"Currying" and "uncurrying" are widely understood by programmers, and "sequencing" and "bundling" are often used in programming for other things, so your idea reduces clarity in favor of some aesthetic preference to avoid turning proper names into verbs when creating new technical terms.

So, I think we're better off just sticking with currying and uncurrying.

Re: Can we stop calling it currying?

#35
post #5

Why call them 'arguments' when nobody is arguing? Currying is the name of the thing. Adding another Enterprise Edition Operational Process Development Pattern like "argument deferral" isn't any better. I mean "Dependency Injection" isn't any easier for beginners to grasp, even though that is what it is. Besides, it isn't argument deferral. That could easily be confused with evaluation order or things like lazy/normal…

From the perspective of a non-functional language, it is argument deferral because you're composing your sequence of functions first, which can then be used by later adding inputs for evaluation. Were you thinking of partial application (not the same as currying)? I would agree that this is not argument deferral, rather it's more like argument presetting.

"Argument deferral" of the type you describe (like partial application, for that matter) is something currying can be used to achieve, but is not what currying is.

So, even if it was proposed when "currying" wasn't well established as the name for currying, it wouldn't be a particularly good choice.

Re: Can we stop calling it currying?

#36
post #20

That's why Clojure calls it "partial" to indicate you're doing partial application http://conj.io/store/v0/org.clojure/clojure/1.7.0-alpha4/clj...

Again, your description refers to "partial application", which is different from currying. I think that many people are comfortable with "currying" only because they think it's the same as partial application. The fact that this is incorrect is good reason to revisit the term.

> I think that many people are comfortable with "currying" only because they think it's the same as partial application.

If currying was the same as partial application, I'd say we don't need the name "currying" and can just use "partial application". So I guess you could say that I am comfortable with currying only because I don't think it is the same as partial application.

Re: Can we stop calling it currying?

#37

Earlier quoted context omitted.

Again, your description refers to "partial application", which is different from currying. I think that many people are comfortable with "currying" only because they think it's the same as partial application. The fact that this is incorrect is good reason to revisit the term.

> I think that many people are comfortable with "currying" only because they think it's the same as partial application. If currying was the same as partial application, I'd say we don't need the name "currying" and can just use "partial application". So I guess you could say that I am comfortable with currying only because I don't think it is the same as partial application.

Good point. It's a bit of a wonder why so many people think of them as equivalent (perhaps they thought currying was a convenient shorthand for partial application). I'm comfortable with a simple campaign to clarify the difference, and I think my suggested terms would be helpful to accomplish that (so rather than replacements, simply informal descriptions of the term).

Re: Can we stop calling it currying?

#38

Earlier quoted context omitted.

From the perspective of a non-functional language, it is argument deferral because you're composing your sequence of functions first, which can then be used by later adding inputs for evaluation. Were you thinking of partial application (not the same as currying)? I would agree that this is not argument deferral, rather it's more like argument presetting.

"Argument deferral" of the type you describe (like partial application, for that matter) is something currying can be used to achieve, but is not what currying is. So, even if it was proposed when "currying" wasn't well established as the name for currying, it wouldn't be a particularly good choice.

I agree, I've revisited my position. Argument deferral and partial application (my term: argument presetting) is something that currying can achieve, but it's not what currying is.

Re: Can we stop calling it currying?

#39

Thanks everyone for the comments. It is interesting to see how widely "currying" is conflated with "partial application". I have to say, I still find the name to be a stumbling block. Perhaps this discussion can help to reverse that trend. I have also learned a good deal more from these comments and further research. It seems my idea of "currying" was not entirely complete. Per the comment herein: "Currying turns pol…

> To summarize, I'm submitting "sequencing" and "bundling" as the two simple verbs that better describe "currying" and "uncurrying". "Currying" and "uncurrying" are widely understood by programmers, and "sequencing" and "bundling" are often used in programming for other things, so your idea reduces clarity in favor of some aesthetic preference to avoid turning proper names into verbs when creating new technical terms…

Good thoughts. I'm interested to see if there are other opinions.

Re: Can we stop calling it currying?

#40
Sometimes you do not want an understandable name for a thing... instead a merely memorable one is far better.

Currying is actually an incredibly specific and universal thing. It's the act of noting that a function space

    (a, b) -> c
is the same as a "higher-order function space"

    a -> (b -> c)
in a very particular way. It's worth it to give this thing it's own name because it's a highly important and unique transformation.

"Curring" and partial application as it exists which take this notion further, such as those which transform (a, b, c) -> d to (a -> b -> c -> d) or (a, b, c) -> d to ((a, c) -> b -> d) are generalizations of the core concept and perhaps don't honestly deserve the name (if you're a stickler).

Merely calling currying and uncurrying by some operational name de-emphasizes these operations. It's like calling a "home run" a "quadruple" in baseball. Sure, it makes sense, but it's really just missing something.

Post reply on HN