[Mono-bugs] [Bug 47927][Blo] New - Problems when using class aliasing in 'using' statements
bugzilla-daemon@bugzilla.ximian.com
bugzilla-daemon@bugzilla.ximian.com
Tue, 26 Aug 2003 13:45:17 -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 pedroabelleira@yahoo.es.
http://bugzilla.ximian.com/show_bug.cgi?id=47927
--- shadow/47927 2003-08-26 13:45:17.000000000 -0400
+++ shadow/47927.tmp.20440 2003-08-26 13:45:17.000000000 -0400
@@ -0,0 +1,68 @@
+Bug#: 47927
+Product: Mono/MCS
+Version: unspecified
+OS:
+OS Details:
+Status: NEW
+Resolution:
+Severity:
+Priority: Blocker
+Component: Misc
+AssignedTo: mono-bugs@ximian.com
+ReportedBy: pedroabelleira@yahoo.es
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL:
+Cc:
+Summary: Problems when using class aliasing in 'using' statements
+
+Description of Problem:
+
+Mcs refuses to compile some valid C# programs wich use class aliasing in
+using statements
+
+Steps to reproduce the problem:
+
+Save n1.cs and test.cs files with this content:
+
+n1.cs:
+
+namespace N1 {
+ public class C1 {
+ }
+}
+
+
+test.cs:
+
+using C1 = N1.C1;
+//using N1;
+
+public class Test {
+ private C1 c1 = null;
+
+ public C1 C1 {
+ get {
+ return C1;
+ }
+ }
+
+ public static void Main() {
+ C1 tmp = C1;
+ }
+}
+
+
+compile both and you get an error:
+
+'test.cs(14) error CS0119: Expression denotes a `type' where a `variable,
+value' was expected
+test.cs(9) error CS0119: Expression denotes a `type' where a `variable,
+value' was expected'
+
+If it's used the commented using statement instead of the other it compiles
+with no complain.
+
+
+Additional Information:
+This bug is related to http://bugzilla.ximian.com/show_bug.cgi?id=47853