News for hackers. Stuff that matters.
Re:Partial functions and total functions by Akronymus on Tuesday December 14, 2021 @05:38AM (#29550238)
> That's called Currying.

Actually no. Currying is converting one function with multiple arguments to a series of functions with one each.

Partial application is supplying some of those arguments and getting back a series of functions that take more arguments.

So, currying = f(x,y,z) -> f'(x)(y)(z)

While partial application = f(x)(y)(z) + x and y being supplied -> f'(z)

Re:Partial functions and total functions by srean on Tuesday December 14, 2021 @09:55AM (#29552168)
> Actually no. Currying is converting one function with multiple arguments to a series of functions with one each

It looked to me that exactly what he was doing, turning the function Add that takes to arguments to a series of two functions that takes one

Re:Partial functions and total functions by Akronymus on Tuesday December 14, 2021 @10:15AM (#29552411)
It seems I misinterpreted your comment then. I thought you were talking about the applying part as currying, which is really common. So I kinda short circuited my reasoning and instantly went for the UMM AKTSCHUALLY.