This is the mail archive of the
kawa@sourceware.org
mailing list for the Kawa project.
Re: CL implementation questions
* Charles Turner [2012-04-08 21:41] writes:
> In CL:
>
> #|kawa:1|# ((as <pair> '(1 2 3)):getCar)
> Invalid parameter, was: gnu.lists.PairWithPosition cannot be cast to
> gnu.mapping.Procedure
> java.lang.ClassCastException: gnu.lists.PairWithPosition cannot be
> cast to gnu.mapping.Procedure
> ...
> #|kawa:2|# (as <pair> '(1 2 3)):getCar
> (1 2 3) :getCar
>
> I'm struggling to see where the difference is happening. I don't know
> how to trace the execution since the difference is happening in
> ModuleExp thread which I don't know how to get a handle on for the
> debugger.
>
> Any ideas?
The difference is probably in the reader: ":foo" in CL syntax is the
keyword foo. In Kawa/Scheme that's written as "foo:" and x:foo is infix
syntax for ($lookup$ x (quasiquote foo)). CL doesn't have that infix
stuff.
Helmut