On Wed, 11 Jul 2001, Stuart Ballard wrote:

> Patrick Doyle wrote:
> > 
> > However, I can't find this reply.  Does anyone know where I might
> > find it?
> 
> Try here:
> 
> http://www.mail-archive.com/[email protected]/msg01820.html

Thanks for the pointer.  Its followups are basically pointing out that
recursive class initialization is well-defined by the JVM spec.

However, I don't think that's the central issue.  There really is a
fundamental initialization problem here:

- Constant pool strings NEED intern().
- Intern() USES a Hashtable.
- Instantiating Hashtable NEEDS Hashtable.<clinit> to be executed.
- Hashtable.<clinit> USES constant pool strings.

As classpath stands, I can't see any way to do this correctly.  Am I
missing it?  What is the sequence of events which causes these things to
be initialized properly?

Then, assuming there is such a correct sequence, doesn't this code still
seem somewhat obscure?  Should it be rewritten so as not to rely so
heavily on Java's precise initialization semantics, just for clarity?

--
Patrick Doyle
[EMAIL PROTECTED]


_______________________________________________
Classpath mailing list
[EMAIL PROTECTED]
http://mail.gnu.org/mailman/listinfo/classpath

Reply via email to