[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: jni-h-fix-warning-1.patch
From: |
Tom Tromey |
Subject: |
Re: jni-h-fix-warning-1.patch |
Date: |
14 May 2004 10:20:35 -0600 |
User-agent: |
Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50 |
I'm checking in the appended. As discussed, while not pedantically
correct according to the C language standard, it does conform to what
Sun does. I'll be putting something similar in libgcj.
Tom
Index: ChangeLog
from Steven Augart <address@hidden>
* include/jni.h.in (_Jv_func): Removed.
(struct JNINativeInterface): Use `void *' for reserved slots.
(struct JNIInvokeInterface): Likewise.
Index: include/jni.h.in
===================================================================
RCS file: /cvsroot/classpath/classpath/include/jni.h.in,v
retrieving revision 1.8
diff -u -r1.8 jni.h.in
--- include/jni.h.in 28 Apr 2004 21:40:33 -0000 1.8
+++ include/jni.h.in 14 May 2004 15:43:15 -0000
@@ -132,12 +132,6 @@
#endif /* __cplusplus */
-#ifdef __cplusplus
-typedef void * (*_Jv_func) (...);
-#else
-typedef void * (*_Jv_func) ();
-#endif
-
#define _Jv_va_list va_list
#ifdef __cplusplus
@@ -202,10 +196,10 @@
struct JNINativeInterface
{
- _Jv_func reserved0;
/* 0 */
- _Jv_func reserved1;
/* 1 */
- _Jv_func reserved2;
/* 2 */
- _Jv_func reserved3;
/* 3 */
+ void *reserved0; /* 0 */
+ void *reserved1; /* 1 */
+ void *reserved2; /* 2 */
+ void *reserved3; /* 3 */
jint (JNICALL *GetVersion) (JNIEnv *);
/* 4 */
jclass (JNICALL *DefineClass) (JNIEnv *, const char *,
jobject, const jbyte *, jsize); /* 5 */
@@ -1355,9 +1349,9 @@
struct JNIInvokeInterface
{
- _Jv_func reserved0;
- _Jv_func reserved1;
- _Jv_func reserved2;
+ void *reserved0;
+ void *reserved1;
+ void *reserved2;
jint (JNICALL *DestroyJavaVM) (JavaVM *);
jint (JNICALL *AttachCurrentThread) (JavaVM *, void **, void *);