[mercury-users] field update terms

Michael Day mikeday at bigpond.net.au
Mon Nov 19 10:11:23 AEDT 2001


Hi,

If I have this:

:- type foo ---> foo(field :: int).

I can't use 'field :=' as a higher order function. But when I add this:

:- func 'field :='(foo, int) = foo.

with no body, I can. How come? Surely the compiler knows about the
function without having to explicitly declare it again?

Michael

--------------------------------------------------------------------------
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