[Mono-bugs] [Bug 52504][Wis] New - We do not flag CS0140 if the target label has a decl

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Wed, 7 Jan 2004 10:28:26 -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 miguel@ximian.com.

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

--- shadow/52504	2004-01-07 10:28:26.000000000 -0500
+++ shadow/52504.tmp.8651	2004-01-07 10:28:26.000000000 -0500
@@ -0,0 +1,33 @@
+Bug#: 52504
+Product: Mono/Compilers
+Version: unspecified
+OS: unknown
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: Unknown
+Priority: Wishlist
+Component: C#
+AssignedTo: martin@ximian.com                            
+ReportedBy: bmaurer@users.sf.net               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: We do not flag CS0140 if the target label has a decl
+
+class a {
+	static void Main ()
+	{
+		goto foo;
+		foo: int i = 0;
+		foo: int a = 1;
+	}
+}
+
+Should not compile,
+on CSC it gives
+
+t.cs(7) error CS0140: The label 'foo' is a duplicate
+
+MCS will compile it.