Author: raja
Date: 2006-01-29 13:31:28 -0500 (Sun, 29 Jan 2006)
New Revision: 56228
Modified:
trunk/mono/mono/metadata/ChangeLog
trunk/mono/mono/metadata/icall.c
Log:
Fix #77397
* icall.c (ves_icall_MonoType_get_IsGenericParameter): Don't
return true if is byref.
(ves_icall_TypeBuilder_get_IsGenericParameter): Likewise.
(ves_icall_MonoType_get_DeclaringType): Return NULL on byref classes.
(ves_icall_MonoType_get_DeclaringMethod): Likewise.
Modified: trunk/mono/mono/metadata/ChangeLog
===================================================================
--- trunk/mono/mono/metadata/ChangeLog 2006-01-29 16:43:14 UTC (rev 56227)
+++ trunk/mono/mono/metadata/ChangeLog 2006-01-29 18:31:28 UTC (rev 56228)
@@ -1,3 +1,12 @@
+2006-01-29 Raja R Harinath <[EMAIL PROTECTED]>
+
+ Fix #77397
+ * icall.c (ves_icall_MonoType_get_IsGenericParameter): Don't
+ return true if is byref.
+ (ves_icall_TypeBuilder_get_IsGenericParameter): Likewise.
+ (ves_icall_MonoType_get_DeclaringType): Return NULL on byref classes.
+ (ves_icall_MonoType_get_DeclaringMethod): Likewise.
+
2006-01-27 Raja R Harinath <[EMAIL PROTECTED]>
Fix tests/find-method.2.il
Modified: trunk/mono/mono/metadata/icall.c
===================================================================
--- trunk/mono/mono/metadata/icall.c 2006-01-29 16:43:14 UTC (rev 56227)
+++ trunk/mono/mono/metadata/icall.c 2006-01-29 18:31:28 UTC (rev 56228)
@@ -1797,6 +1797,8 @@
MONO_ARCH_SAVE_REGS;
+ if (type->type->byref)
+ return NULL;
if (type->type->type == MONO_TYPE_VAR)
class = type->type->data.generic_param->owner->klass;
else if (type->type->type == MONO_TYPE_MVAR)
@@ -2013,7 +2015,7 @@
MONO_ARCH_SAVE_REGS;
if (type->type->type == MONO_TYPE_VAR || type->type->type ==
MONO_TYPE_MVAR)
- return TRUE;
+ return !type->type->byref;
return FALSE;
}
@@ -2023,7 +2025,7 @@
MONO_ARCH_SAVE_REGS;
if (tb->type.type->type == MONO_TYPE_VAR || tb->type.type->type ==
MONO_TYPE_MVAR)
- return TRUE;
+ return !tb->type.type->byref;
return FALSE;
}
@@ -2387,7 +2389,7 @@
MONO_ARCH_SAVE_REGS;
- if (type->type->type != MONO_TYPE_MVAR)
+ if (type->type->byref || type->type->type != MONO_TYPE_MVAR)
return NULL;
method = type->type->data.generic_param->method;
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches