This is the mail archive of the
java-patches@gcc.gnu.org
mailing list for the Java project.
[patch] fix c++ compilation warnings and test cases
- From: Andreas Tobler <toa at pop dot agri dot ch>
- To: Java Patches <java-patches at gcc dot gnu dot org>, Tom Tromey <tromey at redhat dot com>
- Date: Tue, 03 Jul 2007 22:23:11 +0200
- Subject: [patch] fix c++ compilation warnings and test cases
Hi all,
this patch introduced|uncovered a c++ issue in java/lang/Class.h
http://gcc.gnu.org/viewcvs?view=rev&revision=126219
Right now all *.cc testcases fail due to the ? redundant ?
declarations in Class.h. Also the compilation of the *.cc source files
spits this warning:
java/lang/Class.h:276: warning: declaration 'struct
java::lang::ClassLoader' does not declare anything
etc ....
I tested the attached patch on i686-darwin and ppc-darwin.
Maybe a c++ experienced person has an additional comment.
I think it is ok, but I'm not c++ experienced, I only look at the
compilation and the test case run ;)
Tom, does the // Friend classes comment only belong to the declarations
I'd like to remove or also to the following ones?
Ok for main?
Thanks,
Andreas
2007-07-03 Andreas Tobler <a.tobler@schweiz.org>
* java/lang/Class.h: Remove redundant 'class java::*::* declarations.
Index: java/lang/Class.h
===================================================================
--- java/lang/Class.h (revision 126262)
+++ java/lang/Class.h (working copy)
@@ -272,14 +272,6 @@
jbyte _Jv_GetClassState (jclass);
-// Friend classes and functions to implement the ClassLoader
-class java::lang::ClassLoader;
-class java::lang::VMClassLoader;
-
-class java::io::ObjectOutputStream;
-class java::io::ObjectInputStream;
-class java::io::ObjectStreamClass;
-
void _Jv_RegisterClassHookDefault (jclass klass);
void _Jv_RegisterInitiatingLoader (jclass,java::lang::ClassLoader*);
void _Jv_UnregisterInitiatingLoader (jclass,java::lang::ClassLoader*);
@@ -319,7 +311,6 @@
class _Jv_StackTrace;
class _Jv_BytecodeVerifier;
-class java::io::VMObjectStreamClass;
void _Jv_sharedlib_register_hook (jclass klass);