[Mono-bugs] [Bug 49153][Wis] New - Switch statements confused by return

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Wed, 1 Oct 2003 10:37:39 -0400 (EDT)

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 dick@ximian.com.


--- shadow/49153	2003-10-01 10:37:39.000000000 -0400
+++ shadow/49153.tmp.1805	2003-10-01 10:37:39.000000000 -0400
@@ -0,0 +1,31 @@
+Bug#: 49153
+Product: Mono/MCS
+Version: unspecified
+OS: other
+OS Details: 
+Status: NEW   
+Priority: Wishlist
+Component: Misc
+AssignedTo: mono-bugs@ximian.com                            
+ReportedBy: dick@ximian.com               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+Summary: Switch statements confused by return
+Latest CVS mcs and mono.
+The construction "case 1: return("foo"); break;" cases mcs to miscompile
+(specifically, the 'break' causes it to literally break.)
+Running the resulting binary gives:
+** ERROR **: Invalid IL code at IL0021 in .bugger:do_stuff (int): IL_0021:
+br        IL_005d
+Disassembly shows that the do_stuff() method ends at 005c
+Demonstration will be attached.