This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: jc1 segfaults, please help
- From: Bryce McKinlay <bryce at waitaki dot otago dot ac dot nz>
- To: Adam Megacz <gcc at lists dot megacz dot com>
- Cc: java at gcc dot gnu dot org
- Date: Wed, 13 Feb 2002 23:28:24 +1300
- Subject: Re: jc1 segfaults, please help
- References: <86adudvs2c.fsf@megacz.com>
Adam Megacz wrote:
>Hey, is anybody here interested in figuring this out? I know squat
>about the java frontend, so somebody more familiar with it can
>probably figure out in a few minutes what would take me a few weeks.
>
The problem is caused by java/builtins.c (which was recently added). It
sets up a builtin_types array but does not initialize them (see
define_builtin_type). define_builtin gets called with a NULL_TREE type
parameter, and that passes the NULL_TREE to build_decl, which is wrong.
I guess it is just chance that it doesn't crash on other platforms.
The solution would be to do something closer to what
c-common.c:c_common_nodes_and_builtins() does instead, though it seems a
bit crap to duplicate so much code. It would be nice to be able to share
them somehow, but I guess the problem with doing this is the
conflicts/mismatches between Java and C primitive types?
regards
Bryce.