+2000-05-04 Tom Tromey <tromey@cygnus.com>
+
+ * gcj/field.h (JvFieldIsRef): Return false for gnu.gcj.RawData
+ field.
+ * boehm.cc (_Jv_MarkObj): Removed dead code. Use `STATIC', not
+ `0x0008'.
+ Include Modifier.h.
+
2000-05-05 Bryce McKinlay <bryce@albatross.co.nz>
* java/lang/natClass.cc (isInstance): Use __builtin_expect.
#include <gcj/cni.h>
#include <java/lang/Class.h>
+#include <java/lang/reflect/Modifier.h>
#include <java-interp.h>
// More nastiness: the GC wants to define TRUE and FALSE. We don't
{
jclass c = (jclass) addr;
-#if 0
- // The next field should probably not be marked, since this is
- // only used in the class hash table. Marking this field
- // basically prohibits class unloading. --Kresten
- p = (ptr_t) c->next;
- MAYBE_MARK (p, mark_stack_ptr, mark_stack_limit, c, c2label);
-#endif
-
p = (ptr_t) c->name;
MAYBE_MARK (p, mark_stack_ptr, mark_stack_limit, c, c3label);
p = (ptr_t) c->superclass;
// For the interpreter, we also need to mark the memory
// containing static members
- if (field->flags & 0x0008)
+ if ((field->flags & java::lang::reflect::Modifier::STATIC))
{
p = (ptr_t) field->u.addr;
MAYBE_MARK (p, mark_stack_ptr, mark_stack_limit, c, c8clabel);
extern inline jboolean
JvFieldIsRef (jfieldID field)
{
- return field->isRef ();
+ // gnu.gcj.RawData.class is _CL_Q33gnu3gcj7RawData
+ extern java::lang::Class _CL_Q33gnu3gcj7RawData;
+ return field->isRef () && field->type != &_CL_Q33gnu3gcj7RawData;
}
extern inline jobject