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 [EMAIL PROTECTED] http://bugzilla.ximian.com/show_bug.cgi?id=78679 --- shadow/78679 2006-06-20 18:49:16.000000000 -0400 +++ shadow/78679.tmp.20667 2006-06-20 18:49:16.000000000 -0400 @@ -0,0 +1,57 @@ +Bug#: 78679 +Product: Mono: Runtime +Version: 1.1 +OS: All +OS Details: +Status: NEW +Resolution: +Severity: +Priority: Normal +Component: misc +AssignedTo: [EMAIL PROTECTED] +ReportedBy: [EMAIL PROTECTED] +QAContact: [EMAIL PROTECTED] +TargetMilestone: --- +URL: +Cc: +Summary: "System.InvalidProgramException" on casting integers + +Description of Problem: +If you try to cast integers to an object the mono.exe returns "Unhandled +Exception: System.InvalidProgramException: Invalid IL code in [...]: +castclass 0x01000002". Sure, this intend sounds wrong - but its supported +by the ms-framework and can be used to identify objects with integers. (e. +g. you return a object in a procedure which has int32 as result und then +cast it back to the object in another procedure) + +Steps to reproduce the problem: +1. Try to compile this code with ilasm.bat: + +----- +.assembly extern mscorlib { } +.assembly extern System { .publickeytoken = (B7 7A 5C 56 19 34 E0 89) .ver +1:0:5000:0 } +.assembly tmp { } +.module tmp.exe +.subsystem 0x00000003 + +.namespace PB { + .method public static void Exec() cil managed { + .entrypoint + ldc.i4.0 + castclass class [System]System.Net.Sockets.NetworkStream + pop + ret + } //end of .method public static void Exec() cil managed +} //end of .namespace PB +----- + +2. start the exe with mono + +Actual Results: +Unhandled Exception: System.InvalidProgramException: Invalid IL code in +<Module> +:Exec (): IL_0007: castclass 0x01000002 + +Expected Results: +no error _______________________________________________ mono-bugs maillist - [email protected] http://lists.ximian.com/mailman/listinfo/mono-bugs
