Greetings,
I'm trying to decide whether to use 'or', 'case' or 'cond' to pattern
match over a term language and having trouble fully understanding the
differences. (I could just use 'case', but that would be no fun! ...)
'Case' seems to mimic the 'case' that we'd see in functional
languages: successively evaluate guards until one of them succeeds,
then evaluate the associated statement. If more than one guard would
succeed, use the first one.
But what is the difference between this, and 'or' and 'cond'? These
two seem to concurrently execute the guards and then execute the
statement associated with the one that succeeds (so I can't rely on
textual order of guards anymore). What happens, though, if multiple
branches of the 'or' or 'cond' succeed? We'd have two choices for the
statement to execute... ?
Thanks for any insights,
Dan
_________________________________________________________________________________
mozart-users mailing list
[email protected]
http://www.mozart-oz.org/mailman/listinfo/mozart-users