[mercury-users] still The Tuple Construction (with functor)

Ralph Becket rafe at cs.mu.OZ.AU
Fri May 16 11:15:33 AEST 2003


:- type address == int.
:- type value == int.
:- type my_things ---> set_value(address, value) ; ...


	X = set_value(Address, Value)


If you want a *tuple* you'd write


	X = {Address, Value}


A tuple is an (essentially anonymous) vector of values.

- 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