This is the mail archive of the
java@gcc.gnu.org
mailing list for the Java project.
Re: Class.h and Class.java both define zero-arg constructor
Adam Megacz wrote:
>Do you see the definition of Class::Class() in
>gcc/libjava/java/lang/Class.h (around line 221)?
>
Yes. In fact I remember writing that comment ;-)
>I'm doing a static build for mingw; perhaps on other platforms the
>constructor gets inlined or otherwise stripped.
>
>I'm curious to know the "right solution" to this problem, since I'll
>want to incorporate it into the patch I submit next week.
>
What happens if you delete the definition in Class.h and replace it with
a declaration instead? At the moment it looks like either the Class.h
one gets inlined or the Class.java one gets called. Calling the
Class.java one shouldn't be a problem from C++ even though it is
private, assuming it works.
regards
Bryce.