Reason - general function syntax discussion

For what it’s worth, I’m in full agreement with Leo here: starting from scratch, I’d avoid partial application as the default way of building multi-argument functions. But, given the language as it is, making the syntax try to hide that fact seems awkward. I can see how it would help beginners; indeed, when I explain how OCaml works to new people, I don’t explain the partial application story at first.

In the above, don’t confused currying with partial application. Even a language without currying could (and I think should) support a concise syntax for partial application.

By the way, I’m surprised to see Fred Bour’s (@let-def) suggestion that partial application is inefficient to compile as it stands. I thought that was once true, but has basically been fixed. That said, Fred knows the innards of the compiler better than I do, so he’s probably right.

y

1 Like