large Class.forName() patch

Godmar Back gback at
Fri Feb 4 09:04:10 PST 2000

> > 
> > 
> > On Thu, 3 Feb 100, Godmar Back wrote:
> > 
> > Ok, that sounds like a plan. The only other problem I noticed is that
> > Kaffe seems to use plain char* types for class names. These class names
> > really should be in unicode strings or at least UTF8 strings. The
> > current Kaffe implementation means that a \0 embedded in the class name
> > will screw up code that expects a \0 at the end of a string. One
> > of the regression test checks for this.
> > 
> We should probably keep all descriptors/identifiers that were derived 
> from uft8consts in the constant pool as utf8consts all the time.

Actually, I was a bit too fast with my reply.  Fortunately,
we already use utf8consts to store the class names internally.

The problem comes in when we convert from a java string to a C string
to a utf8 string.  Then we do seem to lose such strings.  This is exactly
what we do in java_lang_Class_forName.  What we need is a method to
convert Java strings to utf8consts without going through C strings.

	- Godmar

More information about the kaffe mailing list