[squeak-dev] Fixing support for selectors with underscores

Levente Uzonyi leves at elte.hu
Mon May 2 14:31:06 UTC 2011


On Mon, 2 May 2011, Diogenes Moreira wrote:

> Well... Glorp and GlorpDBX (squeakDBX's Glorp Port) Package, uses some
> accessor with underscore... to maintain compatibility with VW Version
>
> to fix it we have this script
> http://www.squeakdbx.org/files/01/315sh0cs3b31mska30xb1nnigblvdu/underscore.cs
>
> I 'm not sure, if that break other thing, but Glorp Work well..

I guess you missed my point. Squeak _has_ support for underscores in 
selectors out of the box, you can compile the methods and evaluate them 
(after changing the global preference), but the tool support is incomplete 
at the moment.

Your patch will break the existing support code and probably won't work at 
all, because typeTable doesn't contain #leftArrow anymore.


Levente

>
> Best
>
>
> On Mon, May 2, 2011 at 12:49 AM, Levente Uzonyi <leves at elte.hu> wrote:
>> Hi,
>>
>> since Squeak 4.1 it's possible [1] to use underscores in class, method and
>> variable names. System wide support for them is still incomplete though.
>> There are two reasons for this:
>> - our developement process doesn't need this feature
>> - noone wanted to fix it
>>
>> The per-class scoping causes so much trouble, that I'd like to remove it
>> completely, leaving only global preferences. Why?
>> - It doesn't work for
>>  - class names,
>>  - class variable names,
>>  - class side methods.
>> - It doesn't work with code loading tools (e.g. Monticello), because there's
>> no guarantee, that #allowUnderscoreSelectors will be loaded before the
>> methods using underscores that way.
>> - It doesn't work for tools viewing external code.
>>
>> Any objections?
>>
>>
>> Cheers,
>> Levente
>>
>> [1]
>> http://forum.world.st/Selectors-with-underscores-Have-your-cake-and-eat-it-too-td1591416.html
>> [2] http://bugs.squeak.org/view.php?id=7547
>>
>>
>
>


More information about the Squeak-dev mailing list