Herby VojÄÃk wrote:
Pavel Krivanek wrote:
On Wed, May 9, 2012 at 2:38 PM, Herby VojÄÃk<herby@mailbox.sk> wrote:
Pavel Krivanek wrote:
Some next interesting information:
o := ((Metaclass allInstances detect: [:c | c superclass = ProtoObject class]) instVarNamed: #thisClass). 1.
Smalltalk allClassesAndTraits select: [:c | o isKindOf: c] -> an OrderedCollection(Behavior Class ClassDescription Object ProtoObject)
Smalltalk allClasses select: [:c | o class == c] -> an OrderedCollection() "WTF"
My gut feeling says 'o class == o' here. Also it may be interesting to see what is o class class. (o class is not inspectable, is it?)
As I see there is a circle but different one:
dzindzik := (Metaclass allInstances detect: [:c | c superclass = ProtoObject class]). 1. o := dzindzik instVarNamed: #thisClass. 1. o class == dzindzik -> true
It seems there is a problem with inst var indexes... just look at o name (it's printable, only it's a dictionary with dependent fields), something you would not wait from AClass name. Herby P.S.: dzindzik name and dzindzik methodDict are inspectable... method dict is normal, but name is again something strange...