[squeak-dev] problem with filein
Jecel Assumpcao Jr.
jecel at merlintec.com
Fri Aug 13 01:18:57 UTC 2010
Randal L. Schwartz wrote on Date: Thu, 12 Aug 2010 12:46:52 -0700
> Jecel> 1) the class was defined as a subclass of something that was not in the
> Jecel> image, so the system was silently making it a subclass of ProtoObject
> Jecel> instead (though the browser said it was a subclass of Object - very
> Jecel> odd). Didn't we have a warning for this situation?
>
> I can't imagine any case where
>
> Foo subclass: #Bar [...]
>
> should *succeed* if Foo doesn't exist. Can you explain why this isn't fatal?
Indeed, I would expect the compiler to refuse to accept this code since
it can't know what to do with "Foo". But I am guessing that somehow that
is being silently converted into a translation to nil instead.
UndefinedObject does have a
#subclass:instanceVariableNames:classVariableNames:poolDictionaries:cate
gory: instance method to deal with legacy code that has the hack "nil
subclass: #Bar ..." to implement proxies and stuff - it just now
redirects it to the proper ProtoObject class.
-- Jecel
More information about the Squeak-dev
mailing list
|