On 9/2/08, Alasdair McAndrew <amca01 at gmail.com> wrote:
> Can anybody explain this (v 5.15.0):
>
> (%i1) cint("B");
> (%o1) 98
> (%i2) ascii(%);
> (%o2) &b
> (%i3) ascii(98);
> (%o3) &b
> (%i4) cint(%);
> (%o4) 98
>
> Given that the ascii value for "B" is in fact 66, what's going on here?
> What's this "&b"?
Looks like the cint and ascii functions are being supplied by an
obsolete version of stringproc.lisp. Strings used to be implemented
as symbols with names which started with & which accounts for
the &b above. Several months ago Maxima strings were
reimplemented as Lisp strings. I'm not entirely sure but I think 5.15.0
should have a version of stringproc which knows Maxima strings = Lisp strings.
Do you have a stray copy of stringproc.lisp somewhere? If so you
should remove it. If that doesn't help, try it again w/ the latest release,
or at least get the most recent stringproc.lisp from cvs.
HTH
Robert Dodier