|
|
Darren New <dne### [at] sanrrcom> wrote:
> Warp wrote:
> > Darren New <dne### [at] sanrrcom> wrote:
> >>>> I'm saying that C++ does not enforce that you don't change private instance
> >>>> variables from outside the class.
> >>> And this has exactly what to do with whether (compiler-enforced) data
> >>> hiding is a good thing or not?
> >
> >> Because there's two reasons for data hiding: (1) allow more flexibility in
> >> implementation, (2) allow easier debugging.
> >
> >> If you can violate my encapsulation, I don't see the data as especially
> >> encapsulated, is all.
> >
> > You didn't answer my question.
> You said the designs of C# and Java are badly broken because they let you
> get to the private variables of an instance using reflection. You then said
> C++ doesn't let you get to a private variable of an instance. I was
> disputing that claim. That's what compiler-enforced data hiding has to do
> with C++.
> > "Is enforced data hiding a good thing or a bad thing?"
> > "In C++ you can bypass the encapsulation, so it's a bad thing."
> You skipped a bunch of context in between that I thought still applied.
> Maybe you're reading messages in a different order than I am. That's one of
> the problems when a conversation really gets going online. :-)
> If you're not going to apply that context, see my other messages where I
> explain the types of access and seem to be mostly in agreement with you.
> >>> Every single discussion about programming with you turns into C++ bashing,
> >>> no matter what the subject.
> >> I'm happy to bash any other unsafe OO language you might want to name. :-)
> > It's getting really tiresome and old.
> I didn't start out bashing C++ this time. We got pretty far until you
> *seemed to* claim C++ was better at modularity than C# or Java or CLOS. I
> merely listed C++ amongst a half-dozen languages I was criticizing for
> different individual design choices.
You are seriously claiming that when you wrote "like, in unsafe languages,
where a stray pointer can change private variables without going thru the
class methods? :-)" as a reply to my post you were not directly and
exclusively referencing C++, especially with that smiley?
What other half-dozen "unsafe languages, where a stray pointer can change
private variables" were you talking about there?
--
- Warp
Post a reply to this message
|
|