[Mono-bugs] [Bug 82076][Min] New - [GMCS] Does not parse cast to a generic nullable array
bugzilla-daemon at bugzilla.ximian.com
bugzilla-daemon at bugzilla.ximian.com
Wed Jul 11 15:44:55 EDT 2007
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 patperry at stanford.edu.
http://bugzilla.ximian.com/show_bug.cgi?id=82076
--- shadow/82076 2007-07-11 15:44:55.000000000 -0400
+++ shadow/82076.tmp.32677 2007-07-11 15:44:55.000000000 -0400
@@ -0,0 +1,64 @@
+Bug#: 82076
+Product: Mono: Compilers
+Version: 1.2
+OS: other
+OS Details:
+Status: NEW
+Resolution:
+Severity:
+Priority: Minor
+Component: C#
+AssignedTo: rharinath at novell.com
+ReportedBy: patperry at stanford.edu
+QAContact: mono-bugs at ximian.com
+TargetMilestone: ---
+URL:
+Cc:
+Summary: [GMCS] Does not parse cast to a generic nullable array
+
+Description of Problem:
+
+gmcs fails to parse the explicit cast to (T?[]).
+
+
+Steps to reproduce the problem:
+1. Try compiling the code below:
+
+using System;
+
+public class NullableArrayParseBug
+{
+
+ public void Foo<T> ()
+ where T : struct
+ {
+ object o = null;
+ int?[] intArray;
+
+ T?[] array1; // this is ok
+ Nullable<T>[] array2; // so is this
+
+ array1 = (Nullable<T>[]) o; // this is ok
+ intArray = (int?[]) o; // so is this
+ array1 = (T?[]) o; // this is not ok
+ }
+
+}
+
+
+
+Actual Results:
+
+NullableArrayParseBug.cs(18,21): error CS1002: Expecting `;'
+Compilation failed: 1 error(s), 0 warnings
+
+
+Expected Results:
+
+Should compile fine.
+
+How often does this happen?
+
+On Thursdays. Those are the days I compile the code above.
+
+Additional Information:
More information about the mono-bugs
mailing list