[squeak-dev] Class names with underscores

Igor Stasenko siguctua at gmail.com
Fri Jan 21 16:50:24 UTC 2011


On 21 January 2011 17:39, Levente Uzonyi <leves at elte.hu> wrote:
> On Fri, 21 Jan 2011, mkobetic at gmail.com wrote:
>
>> "Igor Stasenko"<siguctua at gmail.com> wrote:
>>>
>>> if you set  'use underscore for selectors' and disable 'underscore for
>>> assignments' in preferences then class names should work as well,
>>> AFAIK.
>>
>> But if that's not how most people will run Squeak, then that's not a
>> reasonable option for me. What are the default settings and are they likely
>> to ever change ?
>
> The default is: underscore assignments are allowed, underscore selectors are
> not. This is fully backwards compatible.
> You can enable underscore selectors for your classes (both senders and
> implementors) in Squeak by implementing the class side method
> #allowUnderscoreSelectors as ^true.
> Browsing the source code has some problems due to a bug
> (http://bugs.squeak.org/view.php?id=7547 ), but the code will work.
>
No only that.

You can't safely recompile source at will, like:
Compiler recompileAll
because parts of code could be filed in using one setting, and other
code loaded when setting is different.
So, you have to live with worst possible solution between:
  - having cake, but can't eat it
  - not having cake, but attempt to eat it
:)

>
> Levente
>




-- 
Best regards,
Igor Stasenko AKA sig.



More information about the Squeak-dev mailing list