On Sat, 11 Aug 2007, Stephen Wilson wrote:

| Gabriel Dos Reis <[EMAIL PROTECTED]> writes:
| > Your suggestion is correct, but the build still fails at the same
| > point.  Looking at the call to expt(x,n) in the Spad code  I don't
| > immediatelt see why it should be well-formed.  Do you see why it is
| > OK? 
| 
| Given:
| 
|    "**": (%,PositiveInteger) -> %
| 
| and
| 
|    x:% ** n:PositiveInteger == expt(x,n)
| 
| we need  
| 
|    expt: (%, PositiveInteger) -> %
| 
| But that is exactly what we get as export when saying:
| 
|     `import RepeatedSquaring(%)'


Yes, the import is supposed to bring expt() in scope.  And expt() is 
indeed brought in scope.

However, judging from the compiler's message it would appear that
RepeatedSquaring expects:

| Here, % certainly satisfies the conditions on the parameter type:
| 
|    SetCategory with "*": (%,%)->%

I don't think it does, in the sense of Spad.
I believe two unnamed categories define distinct categories irrespective of
their bodies. 

-- Gaby


_______________________________________________
Axiom-developer mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/axiom-developer

Reply via email to