Re: Mutability
Re: Mutability
- Subject: Re: Mutability
- From: Ondra Cada <email@hidden>
- Date: Wed, 21 Nov 2001 14:57:37 +0100
Julien,
>
>>>>> Julien Dufour (JD) wrote at Wed, 21 Nov 2001 06:59:05 +0100:
JD> I think you have a wrong approach. You shouldn't have to test whether or
JD> not objects you manipulate are mutable version. Your code should "know"
JD> what kind of object it manipulates.
I beg to differ. It seems to me that the proper OO approach is "give any id
to me; I'll ask it what kind it is, and I'll behave accordingly".
The approach you advocate here -- ie. "give me an object we both know
beforehand which kind it is" seems to me like non-object-oriented, C++-way of
thinking.
Am I completely wrong here? If so, why?
---
Ondra Cada
OCSoftware: email@hidden
http://www.ocs.cz
2K Development: email@hidden
http://www.2kdevelopment.cz
private email@hidden
http://www.ocs.cz/oc