[1095] in java-interest
Re: Assertions in Java (& more)
daemon@ATHENA.MIT.EDU (John D. Mitchell)
Fri Aug 18 17:04:14 1995
Date: Fri, 18 Aug 1995 10:53:42 -0700
From: "John D. Mitchell" <johnm@emf2-003.emf.net>
To: John Barton <jjb@watson.ibm.com>
cc: java-interest@java.sun.com
In-Reply-To: <9508181258.AA30168@jjb.watson.ibm.com>
John Barton writes:
[...]
> This statement as applied to C++ is false. C++ supports derivation from
> interface base classes containing no implementation. C++ supports
> derivation from implementation base classes with or without interfaces.
> C++ supports arbitrary combinations of these kinds of classes.
> "Intertwinedness" is a property of code you may have read, not a property
> of C++; splitting interface from implementation is a standard programming
> practice in C++.
Sigh. The concepts of interface and implementation inheritance are
hopelessly intertwined in C++. Period. Come on, sure C++ allows you to do
just about anything so of course *you* can use you intelligence to use it
in a disciplined manner (or, like most people, don't :-). The point is
that since they are not clear in the language (well, fine, some people
understand it but by far the majority do *not*) there is a lot of
confusion. Confusion is a Bad Thing(tm) in my book.
Scott Meyers' _Effective C++_ book items #35 & #36 exhort C++ programmers
to split off implementation and interface inheritance. None of this is
new. C++ just makes the distinguishment and act of understanding on the
part of the people writing and reading the code rather than a part of the
language.
Geez, every programming language is Turing Complete, right? So what. I
don't want to program a single 'tape' all day long. Heck, we could argue
about interfaces versus implementation inheritance in BASIC. Ouch.
[...is-a modelling is evil...]
> This statement as applied to C++ is false. The construct of separating
> interface from implementation is easily used in C++.
Heheheheheh. Well, *you* may be fortunate enough working at IBM to be
around folks who have a clue about writing C++. I've been around a good
number of people who have little or no clue.
I find it astounding that so many people who talk about C++'s 'virtues'
seem to be people who have *not* had the wonderful experiences of having to
maintain/fix a bunch of other people's C++ attempts.
> For the record, I have no interest in seeing Java emulate C++.
Cool.
Take care,
John
-
Note to Sun employees: this is an EXTERNAL mailing list!
Info: send 'help' to java-interest-request@java.sun.com