[Mono-bugs] [Bug 35900][Nor] New - mcs does not throw error CS0201 on invalid statement.

bugzilla-daemon@rocky.ximian.com bugzilla-daemon@rocky.ximian.com
19 Dec 2002 01:28:28 -0000


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

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

--- shadow/35900	Wed Dec 18 20:28:28 2002
+++ shadow/35900.tmp.5164	Wed Dec 18 20:28:28 2002
@@ -0,0 +1,89 @@
+Bug#: 35900
+Product: Mono/MCS
+Version: unspecified
+OS: GNU/Linux [Other]
+OS Details: 
+Status: UNCONFIRMED   
+Resolution: 
+Severity: Unknown
+Priority: Normal
+Component: Misc
+AssignedTo: triage@ximian.com                            
+ReportedBy: cesar@ciencias.unam.mx               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: mcs does not throw error CS0201  on invalid statement.
+
+Package: Mono/MCS
+Priority: Normal
+Version: from cvs of Dec. 18 2002
+Synopsis: mcs does not throw error CS0201  on invalid statement.
+Bugzilla-Product: Mono/MCS
+Bugzilla-Component: Misc
+
+Description:
+Description of Problem:
+
+Only assignment, call, increment, decrement, and new object expressions
+can be used as a statement
+
+Steps to reproduce the problem:
+1. 
+2. 
+3. 
+
+Actual Results:
+cs0201.cs(11) error CS-0001: Invalid Type definition
+syntax error, expecting OPEN_BRACKET STAR IDENTIFIER
+cs0201.cs(11) error CS1002: Expecting `;'
+cs0201.cs(11) error CS-0025: : Parsing error 
+System.InvalidCastException: Cannot cast from source type to destination
+type
+in <0x0dffa> 00 Mono.CSharp.CSharpParser:yyparse
+(Mono.CSharp.yyParser.yyInput)
+in <0x0006e> 00 Mono.CSharp.CSharpParser:parse ()
+
+Compilation failed: 3 error(s), 0 warnings
+
+
+
+
+
+
+
+
+Expected Results:
+cs0201.cs(11,3): error CS0201: Only assigment, call, increment,
+decrement, and new object expressions can be used as a statement.
+
+How often does this happen?
+Always.
+
+Additional Information:
+
+I added file cs0201.cs to mcs/errors. And paste here too.
+
+
+//
+// cs0201.cs: if a meaningless statement is encountered error cs0201
+have to be thrown
+//
+
+using System;
+
+public class X
+{
+	public static void Main ()
+	{
+		2 * 3;
+	}
+}
+
+
+
+Setting qa contact to the default for this product.
+   This bug either had no qa contact or an invalid one.
+
+