[Mono-bugs] [Bug 74892][Nor] New - mcs permits illegal preprocessor directive
bugzilla-daemon@bugzilla.ximian.com
bugzilla-daemon@bugzilla.ximian.com
Mon, 9 May 2005 23:33:44 -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 michi@zeroc.com.
http://bugzilla.ximian.com/show_bug.cgi?id=74892
--- shadow/74892 2005-05-09 23:33:44.000000000 -0400
+++ shadow/74892.tmp.11059 2005-05-09 23:33:44.000000000 -0400
@@ -0,0 +1,30 @@
+Bug#: 74892
+Product: Mono: Compilers
+Version: 1.1
+OS:
+OS Details:
+Status: NEW
+Resolution:
+Severity:
+Priority: Normal
+Component: C#
+AssignedTo: mono-bugs@ximian.com
+ReportedBy: michi@zeroc.com
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL:
+Cc:
+Summary: mcs permits illegal preprocessor directive
+
+mcs compiles the following without complaint:
+
+#if DEBUG
+// ...
+#endif DEBUG
+
+Note that the #endif directive is illegal. According to the C# spec,
+#endif must be immediately followed by a newline, so "#endif DEBUG" is
+illegal. (Visual Studio correctly diagnoses this error.)
+
+Also note that, according to the C# spec, even whitespace following the
+#endif is illegal. However, Visual Studio permits whitespace.