[squeak-dev] Shadowing "reserved" variables

Nicolas Cellier nicolas.cellier.aka.nice at gmail.com
Thu Jul 18 23:53:21 UTC 2019


Is it really a problem?
Did the system horribly break?
IMO this should just be not recommended.

Le ven. 19 juil. 2019 à 00:39, Chris Muller <asqueaker at gmail.com> a écrit :

> Wow.  We should disallow that.  Those words are reserved.
>
> On Wed, Jul 17, 2019 at 5:52 AM Levente Uzonyi <leves at caesar.elte.hu>
> wrote:
>
>> Hi All,
>>
>> You can currently evaluate the following:
>>
>> [ :self :thisContext |
>>         | nil super true false |
>>         nil := 1.
>>         super := 2.
>>         true := 3.
>>         false := 4.
>>         self + thisContext = (nil + super + true + false) ] value: 4
>> value: 6
>>
>> Is this the expected behavior or should we disallow such oddities?
>>
>> Levente
>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.squeakfoundation.org/pipermail/squeak-dev/attachments/20190719/761c3685/attachment.html>


More information about the Squeak-dev mailing list