This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: Question on String merge
- From: Tom Tromey <tromey at redhat dot com>
- To: Eric Blake <ebb9 at email dot byu dot edu>
- Cc: java at gcc dot gnu dot org
- Date: 14 Mar 2002 12:31:18 -0700
- Subject: Re: Question on String merge
- References: <3C89A542.CB36225F@email.byu.edu>
- Reply-to: tromey at redhat dot com
>>>>> "Eric" == Eric Blake <ebb9@email.byu.edu> writes:
Eric> I'm trying to merge some of my recent changes to String and
Eric> StringBuffer from Classpath into gcj.
I still haven't looked at your patch ...
Eric> Now that both String and Character use gnu.java.lang.CharData in
Eric> Classpath, I'm trying to figure out how to represent that in
Eric> C-style arrays in the native code of gcj. I don't want the
Eric> static data to be defined twice, but I also don't want to
Eric> pollute the namespace.
Eric> +#ifndef CHARTABLES_DEFINE
Eric> +extern const jchar blocks[];
Eric> +#else
Eric> static const jchar blocks[] = {
I don't think this will do what you want.
Instead, rename the array to something like _Jv_char_data_block (you
pick the name -- the prefix is all that is important). Then put a
decl for the array into jvm.h or some place like that. Finally, only
include the header with the table in one file.
Tom