Author: zoltan
Date: 2005-05-13 07:57:53 -0400 (Fri, 13 May 2005)
New Revision: 44494
Modified:
trunk/mcs/class/corlib/System.Reflection.Emit/ChangeLog
trunk/mcs/class/corlib/System.Reflection.Emit/MethodBuilder.cs
Log:
2005-05-13 Zoltan Varga <[EMAIL PROTECTED]>
* MethodBuilder.cs (fixup): Take into account CreateMethodBody as
well.
Modified: trunk/mcs/class/corlib/System.Reflection.Emit/ChangeLog
===================================================================
--- trunk/mcs/class/corlib/System.Reflection.Emit/ChangeLog 2005-05-13
11:45:53 UTC (rev 44493)
+++ trunk/mcs/class/corlib/System.Reflection.Emit/ChangeLog 2005-05-13
11:57:53 UTC (rev 44494)
@@ -1,5 +1,8 @@
2005-05-13 Zoltan Varga <[EMAIL PROTECTED]>
+ * MethodBuilder.cs (fixup): Take into account CreateMethodBody as
+ well.
+
* ConstructorBuilder.cs MethodBuilder.cs: Check that elements of
parameterTypes are not null. Fixes #74928.
Modified: trunk/mcs/class/corlib/System.Reflection.Emit/MethodBuilder.cs
===================================================================
--- trunk/mcs/class/corlib/System.Reflection.Emit/MethodBuilder.cs
2005-05-13 11:45:53 UTC (rev 44493)
+++ trunk/mcs/class/corlib/System.Reflection.Emit/MethodBuilder.cs
2005-05-13 11:57:53 UTC (rev 44494)
@@ -255,7 +255,7 @@
internal void fixup () {
if (((attrs & (MethodAttributes.Abstract |
MethodAttributes.PinvokeImpl)) == 0) && ((iattrs &
(MethodImplAttributes.Runtime | MethodImplAttributes.InternalCall)) == 0)) {
- if ((ilgen == null) ||
(ILGenerator.Mono_GetCurrentOffset (ilgen) == 0))
+ if (((ilgen == null) ||
(ILGenerator.Mono_GetCurrentOffset (ilgen) == 0)) && (code == null))
throw new InvalidOperationException
("Method '" + Name + "' does not have a method body.");
}
if (ilgen != null)
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches