Hi, I did this small experiment
class := Object subclass: #SomeClass.
SystemAnnouncer uniqueInstance
�� �� �� �� when: ClassModifiedClassDefinition
�� �� �� �� do: [ :ann |
�� �� �� �� �� �� �� �� Transcript cr;
�� �� �� �� �� �� �� �� �� �� �� �� crShow: class == ann oldClassDefinition;
�� �� �� �� �� �� �� �� �� �� �� �� crShow: class == ann newClassDefinition ].
��Transcript
�� �� �� �� crShow: class == (Object subclass: #SomeClass instanceVariableNames: 'one' ).
and got
true
false
true
I could understand getting true, false, false, and so having a new object for a new class, or getting false, true, true e.i getting the same object and oldClassDefinition would be a mock that can be used for consistency.
How is all this thing working? Because I���m tracking classes and I need to switch to another object if it���s changed and evaluate some methods. But I can���t evaluate them on newClassDefinition because it���s a different object, and I can���t do it on oldClassDefinition because it���s old���
I would be very grateful.
Uko