[squeak-dev] Fwd: [Pharo-project] type-inference: it works!

Levente Uzonyi leves at elte.hu
Wed Apr 4 11:59:00 UTC 2012

On Wed, 4 Apr 2012, Frank Shearar wrote:

> I ported Francisco Garau's TypeInference engine to Squeak (well,
> changed the one thing I needed to make it run on Squeak), and Marcus
> noted the following:
> Marcus Denker <marcus.denker at inria.fr> says:
>>> It turns out that in Pharo we use Association and in Squeak we use
>>> ReadOnlyVariableBinding; by changing VariableNode >> #isSharedVarNode
>> You should think about cleaning that up... in the SystemDictonary, old classes
>> are ReadOnlyVariableBinding, new ones are Associations. The code to make
>> a binding into a ReadOnlyVariableBinding is never called...
> Given that I know next to nothing about this part of Squeak, I offer
> it up to those more knowledgeable than I for assessment!

Markus is right, the code is not called, but I'm not sure it shouldn't be 
called. Just try the following in a throw-away image:

Object subclass: #Foo
 	instanceVariableNames: ''
 	classVariableNames: ''
 	poolDictionaries: ''
 	category: 'Foo'.
Foo := 1.

The value of Foo will be 1 and your browser will go nuts when you try to 
browse the Foo category.


> frank

More information about the Squeak-dev mailing list