HydraTools and minimal images

Klaus D. Witzel klaus.witzel at cobss.com
Sat Feb 16 09:38:33 UTC 2008


On Sat, 16 Feb 2008 00:15:43 +0100, Igor Stasenko wrote:

> Okay, i think i have a solution which will suit both of us.

For the records: in the previous I just tried to use *your* existing index  
into *your* existing collection :)

> By adding a HydraInterpreter class, instances of which will be used in
> primitives.

That sounds good.

> Class should have two fields: index and handle.
> Primitives then checking:
> - if given argument is of class HydraInterpreter,
> then reads index and handle.

How would you map one of these indexes to its corresponding instance of  
HydraInterpreter, how would your #doit:at: do that mapping?

> then checks if by given index VM having same interpreter handle, as
> specified in HydraInterpreter instance.
> If not, then it tries to search its list of interpreters to find given
> handle, and if found, updates index automatically.
> If handle not found, then primitive fails.
>

Looks like a lot of work (if only for your index); did you compare against  
simple (HydraInterpreter allInstances) ? This (or something like this)  
needs only be done after a new HydraInterpreter was  
created(copied)/started, and, depending on needs, after one of the  
HydraInterpreter instances gone away.

And Smalltalk's collection hierarchy has subclasses which are accessible  
by keys (indexes) which don't need to be stored anywhere (the diagram on  
page 146 of the Blue Book).

/Klaus




More information about the Squeak-dev mailing list