[m-dev.] Re: assertions (was: Assocative predicates)
pets at students.cs.mu.OZ.AU
Thu Apr 23 17:43:27 AEST 1998
On Thu, 23 Apr 1998, Zoltan Somogyi wrote:
> The idea is that (e.g.) you can call p/2 with the first argument
> being of the form f(_) or g(_, _), but p/2 can succeed when the first
> argument is of the form f(_) only; when called with a first argument
> of the form g(_, _), it must fail.
I don't see this as an example of wanting different assertions in different
modes. If p/2 can only succeed with argument 1 of the form f(_), then
that's your assertion, regardless of mode. You might want to also have a
separate precondition on p/2 that the first argument must be of the form
f(_) or g(_,_), but that's a different matter.
-Peter Schachte | The secret of being miserable is to have the
mailto:pets at cs.mu.OZ.AU | leisure to bother about whether you are
http://www.cs.mu.oz.au/~pets/ | happy or not. The cure is occupation.
PGP: finger pets at 18.104.22.168 | -- George Bernard Shaw
More information about the developers