Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 30 Oct 2001 08:18:36 -0800
From:      Terry Lambert <tlambert2@mindspring.com>
To:        Nate Williams <nate@yogotech.com>
Cc:        John Baldwin <jhb@FreeBSD.org>, chat@FreeBSD.org
Subject:   Re: time_t not to change size on x86
Message-ID:  <3BDED2DC.A04B6822@mindspring.com>
References:  <XFMail.011029134349.jhb@FreeBSD.org> <3BDE6ED3.64DC027E@mindspring.com> <15326.50508.909158.688936@caddis.yogotech.com>

next in thread | previous in thread | raw e-mail | index | archive | help
Nate Williams wrote:
> > Java has several problems:
> >
> > 1)    It can't do multiple inheritance
> 
> This is certainly not a problem.  This is a good thing, and one of the
> strengths of Java.  It doesn't bring in all of the *crap* that C++ does.
> In any case, you can perform almost all of the same functionality using
> interfaces, in a much cleaner fashion.  I've yet to find a good example
> of multiple inheritance that couldn't also be done in a simpler fashion
> using Java + inheritance.

I've run into several instances where I needed to marshall
objects from a local node to a remote node, and then reinstance
them, without explicitly knowing anything other than that they
inherit from a particular class, and then later marshall them
again (either back or elsewhere).

Sprite has a nice example of this in their FS implementation,
when doing user space developement of FS code.

Choices (University of Kentucky, circa 1994 Bell Labs sponsored
research) has similar issues, and the whole OS supports object
inheritance.

I've also seen a number of design patterns that could not
be used without a bridge pattern because of the lack of
multiple inheritance (i.e. instead of doing an overlay of
the common parts of two or more patterns, you had to use
reflection to make the common parts act common, even though
they weren't actually common).

Java is really "dumbed down" in order to make it safe for
people who aren't very meticulous about their coding.


> > 2)    You can instance classes without constructing them (the
> >       JavaMail API has a number of examples of this)
> 
> And your point is?

Instance but unconstructed objects are inherently bad.


> > 3)    Strong typing is for weak minds
> 
> That's an elitist attitude from someone who hasn't tried using it.

I've implemented the majority of the Java 1.2 and JavaX 1.2
classes, as well as the JavaMail API in C++.  I've also done
not an inconsiderable amount of work in Rational Rose with
"plain old Java".

I think that historically, we will find that Java will end up
being a compiled language, and will serve predominantly as a
cross platform API.

This is, I think, the reason that Microsoft targeted it for
the "embrace and extend" treatment.

The inability to apply a decent optimizer to JIT'ed code is
just the icing on the cake.

FWIW: dynamic scoping is cool; but garbage collection is not
something one can afford, when designing an embedded system.

The InterJet, going forward, was intended to have much code
in Java (in fact, it had some interesting Java code from the
IBM Almaden research center in it); Archie Cobbs is also a
major contributor to Kaffe, and was one of the primary
developers on the InterJet.

That said, the overhead of using Java was _significant_, and
one of the things we had to do (add a more powerful CPU and
more RAM) pushed in a number of undesirable attributes, as
wll, including, but not limited to, the addition of moving
parts to the product (fans) to dissipate the increased heat
from the increased hardware bulk required.

-- Terry

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-chat" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3BDED2DC.A04B6822>