[mercury-users] Type declaration for a higher order function without arguments?

Peter Hawkins peter at hawkins.emu.id.au
Fri Aug 6 12:53:26 AEST 2004


Hi...

How does one declare a function type that doesn't take arguments?

This is ok:
:- type myfunc(T) = (impure func(int) = T).

This is not:
:- type myfunc(T) = (impure func = T).

Nor is this:
:- type myfunc(T) = (impure func() = T).

What's the secret?

Thanks,
Peter
--------------------------------------------------------------------------
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