Beware, self environment is a SystemDictionary, not a SmalltalkImage

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|

Beware, self environment is a SystemDictionary, not a SmalltalkImage

Nicolas Cellier
Untill recent past, Smalltalk was a SystemDictionary representing both
the namespace and the System.
It was bloated with many messages, and sending messages like:
      self environment garbageCollect.
was correct.

Now, self environment is supposed to answer the namespace object (a
SystemDictionary) not the system object (a SmalltalkImage).
So, some usages are not correct anymore.

See for example #removeUninstantiatedSubclassesSilently.
Fortunately, this message is unsent (quite dangerous isn't it ?).
But IMHO, all senders of #environment should be reviewed.

Nicolas

Reply | Threaded
Open this post in threaded view
|

Re: Beware, self environment is a SystemDictionary, not a SmalltalkImage

Stéphane Ducasse
Hi nicolas

did you check in pharo because if I remember correctly I spent a lot of time doing such a kind of review
and fixes?

Stef

On Jan 30, 2011, at 9:43 PM, Nicolas Cellier wrote:

> Untill recent past, Smalltalk was a SystemDictionary representing both
> the namespace and the System.
> It was bloated with many messages, and sending messages like:
>      self environment garbageCollect.
> was correct.
>
> Now, self environment is supposed to answer the namespace object (a
> SystemDictionary) not the system object (a SmalltalkImage).
> So, some usages are not correct anymore.
>
> See for example #removeUninstantiatedSubclassesSilently.
> Fortunately, this message is unsent (quite dangerous isn't it ?).
> But IMHO, all senders of #environment should be reviewed.
>
> Nicolas
>


Reply | Threaded
Open this post in threaded view
|

Re: Beware, self environment is a SystemDictionary, not a SmalltalkImage

Nicolas Cellier
No, I was just browsing Kernel differences with MC from Squeak and
found this usage in Pharo/#removeUninstantiatedSubclassesSilently.

Nicolas

2011/1/30 Stéphane Ducasse <[hidden email]>:

> Hi nicolas
>
> did you check in pharo because if I remember correctly I spent a lot of time doing such a kind of review
> and fixes?
>
> Stef
>
> On Jan 30, 2011, at 9:43 PM, Nicolas Cellier wrote:
>
>> Untill recent past, Smalltalk was a SystemDictionary representing both
>> the namespace and the System.
>> It was bloated with many messages, and sending messages like:
>>      self environment garbageCollect.
>> was correct.
>>
>> Now, self environment is supposed to answer the namespace object (a
>> SystemDictionary) not the system object (a SmalltalkImage).
>> So, some usages are not correct anymore.
>>
>> See for example #removeUninstantiatedSubclassesSilently.
>> Fortunately, this message is unsent (quite dangerous isn't it ?).
>> But IMHO, all senders of #environment should be reviewed.
>>
>> Nicolas
>>
>
>
>

Reply | Threaded
Open this post in threaded view
|

Re: Beware, self environment is a SystemDictionary, not a SmalltalkImage

Stéphane Ducasse
Ok thanks.
I verified them all and published a fix for that one.

Stef

On Jan 30, 2011, at 10:07 PM, Nicolas Cellier wrote:

> No, I was just browsing Kernel differences with MC from Squeak and
> found this usage in Pharo/#removeUninstantiatedSubclassesSilently.
>
> Nicolas
>
> 2011/1/30 Stéphane Ducasse <[hidden email]>:
>> Hi nicolas
>>
>> did you check in pharo because if I remember correctly I spent a lot of time doing such a kind of review
>> and fixes?
>>
>> Stef
>>
>> On Jan 30, 2011, at 9:43 PM, Nicolas Cellier wrote:
>>
>>> Untill recent past, Smalltalk was a SystemDictionary representing both
>>> the namespace and the System.
>>> It was bloated with many messages, and sending messages like:
>>>      self environment garbageCollect.
>>> was correct.
>>>
>>> Now, self environment is supposed to answer the namespace object (a
>>> SystemDictionary) not the system object (a SmalltalkImage).
>>> So, some usages are not correct anymore.
>>>
>>> See for example #removeUninstantiatedSubclassesSilently.
>>> Fortunately, this message is unsent (quite dangerous isn't it ?).
>>> But IMHO, all senders of #environment should be reviewed.
>>>
>>> Nicolas
>>>
>>
>>
>>
>