Browse thread
RE: [Caml-list] variant with tuple arg in pattern match?
-
Dave Berry
- Marcin 'Qrczak' Kowalczyk
- Frank Atanassow
[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
| Date: | -- (:) |
| From: | Marcin 'Qrczak' Kowalczyk <qrczak@k...> |
| Subject: | RE: [Caml-list] variant with tuple arg in pattern match? |
On Tue, 10 Apr 2001, Dave Berry wrote: > You certainly can avoid currying in functional languages. Currying is a > hack that was created to keep the lambda calculus as simple as possible. It's not a hack. When functions can return functions, there is no need of inventing the concept of multiparameter functions. > 1. Multiple arguments. Fine for the calculus, but in any language with > tuples or records we can just write f(x,y), like everybody else. This is as much of a hack as currying. Why to pack arguments in a tuple when you could simply use currying? > In cases where a function is explicitly returning another (as opposed to > just simulating multiple arguments), I think the explicit binding > describes what is happening more clearly. It's not opposition. This is semantically the same, so there is no need of introducing a syntactic difference. Does map take a function and a list, returning a list, or does it lift a function to a function operating on a list? There is no difference. -- Marcin 'Qrczak' Kowalczyk ------------------- To unsubscribe, mail caml-list-request@inria.fr. Archives: http://caml.inria.fr