From a12fe13ddb02336f99401401bfd8e85d5bd343bc Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Mon, 5 Nov 2001 23:39:54 +0000 Subject: Class.h (Class): Made _Jv_BytecodeVerifier a friend. * java/lang/Class.h (Class): Made _Jv_BytecodeVerifier a friend. * Makefile.in: Rebuilt. * Makefile.am (libgcj_la_SOURCES): Added verify.cc. * verify.cc: New file. * include/java-interp.h (_Jv_count_arguments): Declare. (_Jv_VerifyMethod): Likewise. (class _Jv_InterpMethod): Made _Jv_BytecodeVerifier a friend. (class _Jv_InterpException): Likewise. * resolve.cc (_Jv_count_arguments): Renamed from count_arguments. No longer static. Updated callers. * defineclass.cc (int_bits_to_float): Removed. (long_bits_to_double): Likewise. (prepare_pool_entry): Updated. (handleCodeAttribute): Verify method (commented out for now). From-SVN: r46796 --- libjava/include/java-interp.h | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'libjava/include') diff --git a/libjava/include/java-interp.h b/libjava/include/java-interp.h index 233e738..8eeb094 100644 --- a/libjava/include/java-interp.h +++ b/libjava/include/java-interp.h @@ -43,6 +43,9 @@ void _Jv_DefineClass (jclass, jbyteArray, jint, jint); void _Jv_InitField (jobject, jclass, int); void * _Jv_AllocMethodInvocation (jsize size); +int _Jv_count_arguments (_Jv_Utf8Const *signature, + jboolean staticp = true); +void _Jv_VerifyMethod (_Jv_InterpMethod *method); /* FIXME: this should really be defined in some more generic place */ #define ROUND(V, A) (((((unsigned) (V))-1) | ((A)-1))+1) @@ -54,7 +57,8 @@ class _Jv_InterpClass; class _Jv_InterpMethod; class _Jv_InterpMethodInvocation; -class _Jv_InterpException { +class _Jv_InterpException +{ int start_pc; int end_pc; int handler_pc; @@ -62,6 +66,7 @@ class _Jv_InterpException { friend class _Jv_ClassReader; friend class _Jv_InterpMethod; + friend class _Jv_BytecodeVerifier; }; // Base class for method representations. Subclasses are interpreted @@ -133,6 +138,7 @@ class _Jv_InterpMethod : public _Jv_MethodBase friend class _Jv_ClassReader; friend class _Jv_InterpMethodInvocation; + friend class _Jv_BytecodeVerifier; friend void _Jv_PrepareClass(jclass); }; -- cgit v1.1