[Mono-bugs] [Bug 29843][Min] New - Invalid implicit conversion from Enum to underlying type
bugzilla-daemon@rocky.ximian.com
bugzilla-daemon@rocky.ximian.com
3 Sep 2002 22:24:43 -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 gonzalo@ximian.com.
http://bugzilla.ximian.com/show_bug.cgi?id=29843
--- shadow/29843 Tue Sep 3 18:24:43 2002
+++ shadow/29843.tmp.23861 Tue Sep 3 18:24:43 2002
@@ -0,0 +1,41 @@
+Bug#: 29843
+Product: Mono/MCS
+Version: unspecified
+OS: other
+OS Details:
+Status: NEW
+Resolution:
+Severity:
+Priority: Minor
+Component: Misc
+AssignedTo: mono-bugs@ximian.com
+ReportedBy: gonzalo@ximian.com
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL:
+Cc:
+Summary: Invalid implicit conversion from Enum to underlying type
+
+Steps to reproduce the problem:
+1. Compile this with mcs:
+
+using System;
+
+class A
+{
+ enum B {
+ One,
+ Two
+ }
+
+ static void Main ()
+ {
+ B v = Int32.Parse ("5");
+ }
+}
+
+Actual Results:
+Compilation successfull.
+
+Expected Results:
+case1.cs(12,9): error CS0029: Cannot implicitly convert type 'in' to 'A.B'.