[m-users.] Returning a predicate from a function

Volker Wysk post at volker-wysk.de
Fri Dec 23 01:33:22 AEDT 2022


Am Donnerstag, dem 22.12.2022 um 11:52 +0000 schrieb Mark Clements:
> f_ln(Pred) = (pred(Y::out) is nondet :- Pred(X), Y is math.ln(X)).

Shouldn't that be "Y = math.ln(X)"? Using "is" here seems like an old Prolog
habit.

Volker
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: This is a digitally signed message part
URL: <http://lists.mercurylang.org/archives/users/attachments/20221222/6998ae2e/attachment.sig>


More information about the users mailing list