(mangled_name): Likewise.
(call): Likewise.
* include/java-interp.h (class _Jv_MethodBase): Conditional on
INTERPRETER.
(class _Jv_JNIMethod): Likewise.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@31839
138bc75d-0d04-0410-961f-
82ee72b054a4
+2000-02-07 Tom Tromey <tromey@cygnus.com>
+
+ * jni.cc (add_char): Conditional on INTERPRETER.
+ (mangled_name): Likewise.
+ (call): Likewise.
+ * include/java-interp.h (class _Jv_MethodBase): Conditional on
+ INTERPRETER.
+ (class _Jv_JNIMethod): Likewise.
+
2000-02-04 Warren Levy <warrenl@cygnus.com>
* Makefile.am: Added MPN.java and BigInteger.java.
#include <jvm.h>
#include <java-cpool.h>
-// Base class for method representations. Subclasses are interpreted
-// and JNI methods.
-class _Jv_MethodBase
-{
-protected:
- // The class which defined this method.
- _Jv_InterpClass *defining_class;
-
- // The method description.
- _Jv_Method *self;
-};
-
#ifdef INTERPRETER
#pragma interface
friend class _Jv_InterpMethod;
};
+// Base class for method representations. Subclasses are interpreted
+// and JNI methods.
+class _Jv_MethodBase
+{
+protected:
+ // The class which defined this method.
+ _Jv_InterpClass *defining_class;
+
+ // The method description.
+ _Jv_Method *self;
+};
+
class _Jv_InterpMethod : public _Jv_MethodBase
{
_Jv_ushort max_stack;
ffi_type * arg_types[0];
};
-#endif /* INTERPRETER */
-
class _Jv_JNIMethod : public _Jv_MethodBase
{
// The underlying function. If NULL we have to look for the
friend void _Jv_PrepareClass(jclass);
};
+#endif /* INTERPRETER */
+
#endif /* __JAVA_INTERP_H__ */
Libgcj License. Please consult the file "LIBGCJ_LICENSE" for
details. */
-// Note: currently we take the approach of not checking most
-// arguments. Instead we could do more checking conditionally (e.g.,
-// if DEBUG is defined). That might be beneficial in some cases,
-// though to me it seems that one could just as easily use the
-// debugger.
-
#include <config.h>
#include <stddef.h>
\f
+#ifdef INTERPRETER
+
// Add a character to the buffer, encoding properly.
static void
add_char (char *buf, jchar c, int *here)
}
// The actual call to the JNI function.
+ // FIXME: if this is a static function we must include the class!
ffi_raw_call (cif, (void (*) (...)) _this->function, ret, args);
do
JvThrow (env.ex);
}
+#endif /* INTERPRETER */
+
\f
#define NOT_IMPL NULL