[mercury-users] Idea for a currying library
Ralph Becket
rbeck at microsoft.com
Mon Jan 17 22:19:36 AEDT 2000
> Peter Schachte's preferred notation shares one advantage with lambda
> notation which the callperm stuff lacks: the form that is abstracted
> can be compound. On the other hand, anything more than a single goal
> is likely to merit a comment or two, so putting it on more than one
> line is going to pay off in readability anyway and we might as well
> use lambda-notation.
I'm inclined to agree, although I find the need to supply mode and
determinism declarations for lambdas in Mercury makes code look
clumsy and cumbersome. I would like some sort of facility for
turning on mode inference on a selective basis, e.g.
:- pragma infer_modes(foo/3).
foo(X, Y, Z) :- <<something containing an unmoded lambda>>.
I don't mind supplying top-level modes for foo/3, but it does grate
having to write them for lambdas where it should be bleeding obvious
what is meant in most cases.
Ralph
--------------------------------------------------------------------------
mercury-users mailing list
post: mercury-users at cs.mu.oz.au
administrative address: owner-mercury-users at cs.mu.oz.au
unsubscribe: Address: mercury-users-request at cs.mu.oz.au Message: unsubscribe
subscribe: Address: mercury-users-request at cs.mu.oz.au Message: subscribe
--------------------------------------------------------------------------
More information about the users
mailing list