"Bill Page" <[EMAIL PROTECTED]> writes:

> Martin,

> Are you saying that it should not be necessary to give the interpreter
> such mode hints?

Not quite sure, but I'd say: no!

In any case, look again what the interpreter is doing:

(1) -> l1: List POLY INT := [a,b]; l2: List POLY INT := [x,y];

                                                Type: List Polynomial Integer
(2) -> )se me bo on
(2) -> dot(l1,l2)

 Function Selection for dot
      Arguments: (LIST POLY INT,LIST POLY INT) 
   -> no appropriate dot found in List Polynomial Integer 
   -> no appropriate dot found in Polynomial Integer 
   -> no appropriate dot found in List Polynomial Integer 
   -> no appropriate dot found in Polynomial Integer 

 Modemaps from Associated Packages 
   no modemaps

 Remaining General Modemaps 
   [1] (D,D) -> D1 from D
            if D has VECTCAT D1 and D1 has TYPE and D1 has RING
   [2] (D,D) -> D1 from D
            if D has DIRPCAT(D2,D1) and D1 has TYPE and D1 has RING
   -> no appropriate dot found in Vector Polynomial Integer 
   -> no function dot found for arguments (LIST POLY INT,LIST POLY INT) 
[...]

it doesn't try the natural thing: coercing List POLY INT to Vector POLY INT,
even though it is looking at the right modemap...

It would be great if somebody could try to *really* understand that algorithm!
(Only guessing:  there is currently no coerce: List D -> Vector D)

Apart from that:

(1) -> dot([1,2],[a,b])
   There are 2 exposed and 2 unexposed library operations named dot 
      having 2 argument(s) but none was determined to be applicable. 
      Use HyperDoc Browse, or issue
                               )display op dot
      to learn more about the available operations. Perhaps 
      package-calling the operation or using coercions on the arguments
      will allow you to apply the operation.
 
   Cannot find a definition or applicable library operation named dot 
      with argument type(s) 
                            List PositiveInteger
                       List OrderedVariableList [a,b]
      
      Perhaps you should use "@" to indicate the required return type, 
      or "$" to specify which version of the function you need.

Why on earth is it interpreting [a,b] as List OrderedVariableList [a,b]?  That
doesn't make sense!


Martin


-------------------------------------------------------------------------
This SF.net email is sponsored by the 2008 JavaOne(SM) Conference 
Don't miss this year's exciting event. There's still time to save $100. 
Use priority code J8TL2D2. 
http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone
_______________________________________________
open-axiom-devel mailing list
open-axiom-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/open-axiom-devel

Reply via email to