[cl-containers-devel] Error loading the cl-containers in REPL

Gary King gwking at metabang.com
Sat Sep 27 20:27:52 UTC 2008


Hi Watt,

Thanks for your interest in cl-containers.

>
> I am new to cl-containers.  I using Clisp on Linux.  I am able load  
> cl-containers through asdf without any error.

Good!

> But when I issue (setf *new-hash* (cl-containers:make-container  
> 'associative-container :test #'equal)) in REPL, I  get this error  
> FIND-CLASS: ASSOCIATIVE-ARRAY does not name a class [Condition of  
> SIMPLE ERROR].

I'm guessing that the error was closer to:

>> Error: No class named: associative-container.
>>   [condition type: program-error]

This happens because #'make-container is almost exactly like #'make- 
instance. It's first argument is the name of the class to make (*).  
You asked for the class 'associative-container but you want to ask for  
'cl-containers:associative-container.

> When I change the package (in-package :containers), it works fine.   
> So I am just not sure what else that was missing in how I load the  
> classes.

Right. If you're in the cl-containers package (or if you've used the  
package) then the above will work as will:

>> (setf *new-hash* (make-container 'associative-container :test  
>> #'equal))

> Thanks for your help.


My pleasure. Let me know how things work for you. I'm sure that there  
is some code rot in cl-containers and I'd love to keep it cleaned up  
and running.

Thanks,
--
Gary Warren King, metabang.com
Cell: (413) 559 8738
Fax: (206) 338-4052
gwkkwg on Skype * garethsan on AIM







More information about the cl-containers-devel mailing list