[NBLUG/talk] If you love him/it so much, then defend him/it.

Andru Luvisi luvisi at andru.sonoma.edu
Sun May 25 11:02:10 PDT 2003


On Sun, 25 May 2003, Edward Mendoza wrote:
[snip]
> Is Java a language that is better at abstraction than C++ but is also slower
> than C++?
[snip]

I think it is accurate to say that Sun tried to make a language that was
better at abstraction while sacrificing as little speed as possible.  I
have no idea how well they succeeded.

I haven't used Java in years, and I am still bitter about the failure of
"write once, run anywhere".  I was a big believer in the Java dream, and
once I found out how hard it is to write Java code that runs the same
everywhere I was very disillusioned.

I have had several bad experiences with Java based applications, but I
have no idea if the problems were with the Java implementations or with
the applications themselves.

Although I haven't used it, I hear good things about gcj, the GNU compiler
for Java, which compiles to native machine code.  It's a part of gcc, see
http://gcc.gnu.org/ .  I have no idea how compiled Java code compares to
similar compiled C++ code when it comes to speed.

As far as abstraction goes, I remember thinking that Java was weaker than
C++, but that was many years ago and Java has evolved quite a bit since
the last time I looked at it.  Garbage collection is a plus (although you
can get it for C and C++ too.  See
http://www.hpl.hp.com/personal/Hans_Boehm/gc/).  I consider the lack of
multiple inheritance to be a weakness of Java.  I know many people
consider it a strength because it prevents some types of confusion.

Andru
-- 
Andru Luvisi, Programmer/Analyst

Quote Of The Moment:
  "Taking the envelope and pencil in his otherwise empty hands, the
  medium feels it, stares into space, grunts, foams at the mouth, and
  otherwise becomes very psychic."
  	- Theodore Annemann




More information about the talk mailing list