This is the mail archive of the java@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Multiple method definition errors building GCJ 3.3


On Thu, 19 Dec 2002, Ranjit Mathew wrote:
> Trying to figure out the cause of this error, I noticed that they
> were being thrown for methods that were defined inline in gcjh
> generated headers like "java/lang/String.h", etc. I don't know
> C++ properly, but it seems that these methods are not being
> inlined for some reason even though almost all of them are
> trivial "return foo;" type methods.

I didn't see a reply to this...

> Should gcjh explicitly mark them "inline"?

Perhaps.  You want the method body to be expanded once, somehow.  (My C++
is rusty and not getting any better these days.)

> Why doesn't this problem come up on other platforms?

GNU/Linux emits these methods with weak symbols.  Win32 doesn't support
weak symbols.  That could be the reason.

Jeff


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]