On Thu, Jul 17, 2008 at 11:43 PM, Bill Page <[EMAIL PROTECTED]> wrote: > On Thu, Jul 17, 2008 at 11:33 PM, Yixin Cao > <[EMAIL PROTECTED]> wrote: >> >> >> On Thu, Jul 17, 2008 at 10:13 PM, Bill Page <[EMAIL PROTECTED]> >> wrote: >>> >>> On Thu, Jul 17, 2008 at 10:49 PM, Yixin Cao wrote: >>> > With this patch, categories can be declared conditionally with >>> > 'is' operator, e.g. >>> > >>> > Fake(T:Type, a:T): Public == Private where >>> > Public == CoercibleTo OutputForm with >>> > if T is Integer and a is 10 then CommutativeRing >>> > if T is Matrix(Integer) then leftUnitary >>> > >>> > ... >>> >>> That looks pretty cool! I'd like to know more. >>> >>> Can you tell me where I can find details of the semantics and examples >>> of other uses of the 'is' operator in SPAD? So far as I recall, only >>> 'has' is discussed in chapters 11, 12, 13 of the Axiom book. Where >>> else can I look? >> >> >> ATM I cannot answer your question. > > The only documentation about 'is' that I know of is in the Boot > language. See Section "2.3.11 Patterns" of src/boot/Makefile.pamphlet, > or here: > > http://axiom-wiki.newsynthesis.org/axiom--test--1/src/boot/Makefile > > But not all of Boot is available in Spad.
It is correct that Boot is not included in Spad. However, the compiler of the base AXIOM system is already supposed to handle 'is' for domains. What disappoints me is that I've asked Yixin to explain why he thinks his code (in particular the runtime part) is correct. Note also that there are traces in the system that seem to indicate that 'is' is also supposed to work for pattern matching (not just for Old Boot codes). > > The thing that concerns me is that your new use of 'is' might not be > compatible with it's use in pattern matching in Boot. It should be -- but in the code posted by Yixin, I don't see that. The pattern matching is *supposed* to be supported for Spad also. ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ open-axiom-devel mailing list open-axiom-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/open-axiom-devel