[squeak-dev] Fixing support for selectors with underscores

Tobias Pape Das.Linux at gmx.de
Mon May 2 16:38:34 UTC 2011


Am 2011-05-02 um 05:49 schrieb Levente Uzonyi:

> 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?

Yes, I think per-class scoping is important.
I think it is valuable to be able to ‘tune’
your sub-tree of the inheritance tree without interference
with the system. I don't think it is wise to force
the whole system to be underscore-selector compatible
because three or so classes (just an example) need them.
Especially, these three classes never know what setting
they are loaded into. Perhaps there is some very old code
that chokes on underscores, so why enable them globally when
it is not needed globally. I'd even opt for the preference
#allowUnderscore* to be implemented on Object, so this is only
virtually global.
   Make as least things global as possible.

You said:
> - 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.

I would take that as a reason to fix monticello.
It is the same problem for #parserClass #compilerClass
etc.pp. You don't want to remove that support, too, do you?

So Long,
	-Tobias


More information about the Squeak-dev mailing list