[KCP] about VM
sql.mawi at t-link.de
Sun Jun 29 12:29:00 UTC 2003
>> I'm sorry to say that I really don't like the way some of this is
>> Certainly cleaning up SystemDictionary is a Good Thing but I'm
>> having trouble swallowing splitting code into so many places on a
>> tenuous basis.
>> No, I'd claim that a class named something relatively simple
>> like 'System' is the place for most of this, along with many of the
>> things I've seen in discussions of 'Image'. And again, I'd go for
>> class-side code since there is really only a single System around
>> at any
>> one time.
Yes, that is IMHO exactly the right way to go.
>For the class side of life, we have one strong opinion about what
>should be put on class side: class
>behavior! Using class methods to represent instance behavior is a
>sick behavior on the long term.
There is no instance behavior if there is maximal one instance! In
case you don't believe this, here is the proof: you can put all
methods on the class side. And because of the missing instances there
is no real class behavior either!
It may be even misleading to create a special class with an artificial
instance in such a case, the inexperienced code-reader may think that
there may be different 'vms' 'images' 'systems' etc. SHe may entirely
miss, that that is no real object at all! ( it is only a
representation of something outside the OO-system ).
>I do not understand why having two small classes is not better that a
>big fat one. Especially because we are trying
>to create coherent abstractions.
>About the general purpose, note that we believe that having class
>with well identified responsibility is the best way to create
>abstraction. We believe that after others can build on them, enrich
>them. The process is important. I saw that we creating SpaceTally
>from spaceTallyOn: and related methods.
What coherent abstractions do you want to create on something like VM,
which obviously has not even one real instance and therefore no real
class ( in an OO sense )?
Stephane, your OO-arguments simply don't work for these special kind
of methods and 'representation-objects'.
Furthermore I must say, you should not forget that 97% of all Squeak
users and potential users have no interest in arcane research
experiments, they expect to have _one_ System and _one_
SystemNavigator: they prefer to say XYZ doThat instead of XYZ default
Keep it simple.
peace and regards,
More information about the Squeak-dev