[Ecls-list] Maxima + ECL type coercion failure

Robert Dodier robert.dodier at gmail.com
Sun May 18 06:13:44 UTC 2008


Hello,

Good news --- Maxima patches-for-ecl-branch + CVS ECL,
when interpreted, runs the Maxima test suite (run_testsuite())
with just a few errors. There are 3 kinds of errors.
(0) an error in the display code -- display2d:false makes it go away.
Do that before trying to run the test suite.
(1) simplification errors -- equivalent but non-identical expressions.
These may be quite subtle. I'll try to figure out what's going on.

(2) a specific type coercion failure in HANKEL-1 (src/bessel.lisp).
ECL barfs on (coerce z '(complex flonum)) near the top of the function.
Actually even (coerce 1 'flonum) fails, although (coerce 1 'double-float)
is OK. Here is the deftype for flonum (src/clmacs.lisp):

(deftype flonum (&optional low high)
  (cond (high
     `(double-float ,low ,high))
    (low
     `(double-float ,low))
    (t
     'double-float)))

I can make the problem go away by just changing that to
(deftype flonum (&optional low high) 'double-float)
but I'd like to use the other definition if possible; I think it should work.

Any advice about (2) would be appreciated. Thanks for your help.

Robert Dodier




More information about the ecl-devel mailing list