Le 07/11/2015 18:21, Sean P. DeNigris a écrit :
Issue 16947: Class-side Inst Var "#name" Allowed, But Breaks System
https://pharo.fogbugz.com/f/cases/16947/Class-side-Inst-Var-name-Allowed-But-Breaks-System

If you like adventure, try the following:
   class := Object subclass: #MyClass
   instanceVariableNames: ''
   classVariableNames: ''
   category: 'MyBug'.
   class class compile: 'break name := 1'.
   class break.
   MyClass browse

"Emergency evaluator :/"

To restore the system:
     class instVarNamed: #name put: #MyClass.

Now here's the kicker - there doesn't seem to a class-side instVarNamed:
#name! It's not defined in Object or ProtoObject.

When I try that, I can avoid the emergency evaluator if I try to browse with an already opened system browser -> I get a red window instead with a Metaclass>>#name problem.

Thierry

NB. Also a bug in Pharo 4.0



-----
Cheers,
Sean
--
View this message in context: 
http://forum.world.st/Woe-unto-thee-who-assigns-to-class-side-name-tp4859734.html
Sent from the Pharo Smalltalk Developers mailing list archive at Nabble.com.




Reply via email to