2004-09-01 Martin Baulig <martin@ximian.com>
authorMartin Baulig <martin@novell.com>
Wed, 1 Sep 2004 06:54:59 +0000 (06:54 -0000)
committerMartin Baulig <martin@novell.com>
Wed, 1 Sep 2004 06:54:59 +0000 (06:54 -0000)
* metadata.h (MONO_TYPE_ISREFERENCE): Call
mono_metadata_generic_inst_is_valuetype() if we're a generic
instance to check whether our underlying type is a reference type.

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

mono/metadata/ChangeLog
mono/metadata/metadata.h

index 6348109f859681a81f18436b788c20c3a5321eb2..93df6fb6cce83fdf78bb79b5ae2bc165049c78cd 100644 (file)
@@ -1,3 +1,9 @@
+2004-09-01  Martin Baulig  <martin@ximian.com>
+
+       * metadata.h (MONO_TYPE_ISREFERENCE): Call
+       mono_metadata_generic_inst_is_valuetype() if we're a generic
+       instance to check whether our underlying type is a reference type.
+
 2004-09-01  Martin Baulig  <martin@ximian.com>
 
        * metadata.c (mono_type_size): If we're a generic instance, call
index bc97c675b4da07678426805d009ee64841a633d2..93215d141a56035eb7a45892e0c97dc0f6cef515 100644 (file)
@@ -17,7 +17,7 @@
 #define MONO_TYPE_ISSTRUCT(t) (!(t)->byref && (((t)->type == MONO_TYPE_VALUETYPE && !(t)->data.klass->enumtype) || ((t)->type == MONO_TYPE_TYPEDBYREF) || (((t)->type == MONO_TYPE_GENERICINST) && mono_metadata_generic_inst_is_valuetype ((t)->data.generic_inst))))
 #define MONO_TYPE_IS_VOID(t) ((t) && ((t)->type == MONO_TYPE_VOID) && !(t)->byref)
 #define MONO_TYPE_IS_POINTER(t) ((t) && (((t)->byref || ((t)->type == MONO_TYPE_I) || (t)->type == MONO_TYPE_STRING) || ((t)->type == MONO_TYPE_SZARRAY) || ((t)->type == MONO_TYPE_CLASS) || ((t)->type == MONO_TYPE_CLASS) || ((t)->type == MONO_TYPE_OBJECT) || ((t)->type == MONO_TYPE_ARRAY) || ((t)->type == MONO_TYPE_PTR)))
-#define MONO_TYPE_IS_REFERENCE(t) ((t) && (((t)->type == MONO_TYPE_STRING) || ((t)->type == MONO_TYPE_SZARRAY) || ((t)->type == MONO_TYPE_CLASS) || ((t)->type == MONO_TYPE_OBJECT) || ((t)->type == MONO_TYPE_ARRAY)))
+#define MONO_TYPE_IS_REFERENCE(t) ((t) && (((t)->type == MONO_TYPE_STRING) || ((t)->type == MONO_TYPE_SZARRAY) || ((t)->type == MONO_TYPE_CLASS) || ((t)->type == MONO_TYPE_OBJECT) || ((t)->type == MONO_TYPE_ARRAY)) || (((t)->type == MONO_TYPE_GENERICINST) && !mono_metadata_generic_inst_is_valuetype ((t)->data.generic_inst)))
 #define MONO_CLASS_IS_INTERFACE(c) ((c->flags & TYPE_ATTRIBUTE_INTERFACE) || (c->byval_arg.type == MONO_TYPE_VAR) || (c->byval_arg.type == MONO_TYPE_MVAR))
 
 typedef struct _MonoClass MonoClass;