[mercury-users] Newbie questions about typeclasses

Critterrathman at aol.com Critterrathman at aol.com
Thu Apr 26 03:46:53 AEST 2001


>>It is generally not
>>necessary to give mode declarations for _functions_ since, if no mode
>>declaration is given, a default mode is assumed where every argument
>>has mode 'in', the result has mode 'out' and the determinism is 'det'.

As a neophyte writing code, being explicit with the modes kind of helped me 
see the consitency between functions and predicates.  I went ahead and 
stripped them out of the example on the web page, which does help shorten the 
code up and improve readability a tad.

Thanks.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mercurylang.org/archives/users/attachments/20010425/d1ea4ea2/attachment.html>


More information about the users mailing list