[Mono-bugs] [Bug 71742][Nor] New - mcs miscompiles Microsoft.JScript

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Tue, 25 Jan 2005 16:33:07 -0500 (EST)


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by vargaz@gmail.com.

http://bugzilla.ximian.com/show_bug.cgi?id=71742

--- shadow/71742	2005-01-25 16:33:07.000000000 -0500
+++ shadow/71742.tmp.5305	2005-01-25 16:33:07.000000000 -0500
@@ -0,0 +1,63 @@
+Bug#: 71742
+Product: Mono: Compilers
+Version: unspecified
+OS: 
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Normal
+Component: C#
+AssignedTo: mono-bugs@ximian.com                            
+ReportedBy: vargaz@gmail.com               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: mcs miscompiles Microsoft.JScript
+
+Looking at the IL of Microsoft.JScript.dll produced by mcs HEAD, there is
+this method:
+
+<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
+    // method line 94
+    .method privatescope virtual  hidebysig  newslot 
+           instance default class [mscorlib]System.Reflection.MethodInfo
+IReflect.GetMethod (string 'value', valuetype
+[mscorlib]System.Reflection.BindingFlags 'value', class
+[mscorlib]System.Reflection.Binder args, class [mscorlib]System.Type[]
+thisOb, valuetype [mscorlib]System.Reflection.ParameterModifier[] args) 
+cil managed 
+    {
+        // Method begins at RVA 0x2798
+	.override class [mscorlib]System.Reflection.IReflect::GetMethod
+	// Code size 22 (0x16)
+	.maxstack 8
+	IL_0000:  ldarg.0 
+	IL_0001:  ldarg.1 
+	IL_0002:  ldarg.2 
+	IL_0003:  ldarg.3 
+	IL_0004:  ldarg 2
+
+	IL_0008:  nop 
+	IL_0009:  nop 
+	IL_000a:  ldarg 3
+
+	IL_000e:  nop 
+	IL_000f:  nop 
+	IL_0010:  call instance class [mscorlib]System.Reflection.MethodInfo class
+Microsoft.JScript.ScriptObject::GetMethod(string, valuetype
+[mscorlib]System.Reflection.BindingFlags, class
+[mscorlib]System.Reflection.Binder, class [mscorlib]System.Type[],
+valuetype [mscorlib]System.Reflection.ParameterModifier[])
+	IL_0015:  ret 
+    } // end of method JSObject::instance default class
+[mscorlib]System.Reflection.MethodInfo IReflect.GetMethod (string 'value',
+valuetype [mscorlib]System.Reflection.BindingFlags 'value', class
+[mscorlib]System.Reflection.Binder args, class [mscorlib]System.Type[]
+thisOb, valuetype [mscorlib]System.Reflection.ParameterModifier[] args) 
+
+<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
+
+Notice how the call to the GetMethod method, which takes 5 parameters, but
+there are 6 items on the stack in a weird order.