2002-10-08 Martin Baulig <martin@gnome.org>
authorMartin Baulig <martin@novell.com>
Tue, 8 Oct 2002 14:00:40 +0000 (14:00 -0000)
committerMartin Baulig <martin@novell.com>
Tue, 8 Oct 2002 14:00:40 +0000 (14:00 -0000)
* debug-mono-symfile.c: Ignore classes with a pending init for the
moment.

svn path=/trunk/mono/; revision=8061

mono/metadata/ChangeLog
mono/metadata/debug-mono-symfile.c

index b5626cb91b351c57c889cd6c017debe41de84ddd..2f350e6ec91bd3d84a69edba0b828fc0394df662 100644 (file)
@@ -1,3 +1,8 @@
+2002-10-08  Martin Baulig  <martin@gnome.org>
+
+       * debug-mono-symfile.c: Ignore classes with a pending init for the
+       moment.
+
 2002-10-03  Dick Porter  <dick@ximian.com>
 
        * threads.c: Freebsd pthread_t is a pointer
index 31f7ae27e14983f22b8f5546b2489c45eeff8f36..c1edd8c491e78c954321568598d9765718c69044 100644 (file)
@@ -769,8 +769,12 @@ write_type (MonoType *type)
        if (kind == MONO_TYPE_OBJECT) {
                klass = mono_defaults.object_class;
                kind = MONO_TYPE_CLASS;
-       } else if ((kind == MONO_TYPE_VALUETYPE) || (kind == MONO_TYPE_CLASS))
+       } else if ((kind == MONO_TYPE_VALUETYPE) || (kind == MONO_TYPE_CLASS)) {
                klass = type->data.klass;
+               retval = g_hash_table_lookup (class_table, klass);
+               if (retval)
+                       return retval;
+       }
 
        switch (kind) {
        case MONO_TYPE_SZARRAY:
@@ -786,6 +790,11 @@ write_type (MonoType *type)
                GHashTable *method_slots = NULL;
                int i;
 
+               if (klass->init_pending) {
+                       size = sizeof (int);
+                       break;
+               }
+
                mono_class_init (klass);
 
                retval = g_hash_table_lookup (class_table, klass);
@@ -893,6 +902,11 @@ write_type (MonoType *type)
                int base_offset = kind == MONO_TYPE_CLASS ? 0 : - sizeof (MonoObject);
                int i, j;
 
+               if (klass->init_pending) {
+                       *((int *) ptr)++ = -1;
+                       break;
+               }
+
                g_hash_table_insert (class_table, klass, retval);
 
                if (klass->enumtype) {