[Mono-bugs] [Bug 74797][Nor] New - Improper scoping for nested classes.

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Mon, 2 May 2005 08:41:21 -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 sgay@bigorno.net.

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

--- shadow/74797	2005-05-02 08:41:21.000000000 -0400
+++ shadow/74797.tmp.7174	2005-05-02 08:41:21.000000000 -0400
@@ -0,0 +1,56 @@
+Bug#: 74797
+Product: Mono: Compilers
+Version: 1.1
+OS: other
+OS Details: Debian Sarge (but probably: all)
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Normal
+Component: C#
+AssignedTo: mono-bugs@ximian.com                            
+ReportedBy: sgay@bigorno.net               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: Improper scoping for nested classes.
+
+Please fill in this template when reporting a bug, unless you know what you
+are doing.
+Description of Problem: when a class C inherits from class A, C can access
+A's protected members, but a nested class within C can not. 
+
+
+Steps to reproduce the problem:
+1. Compile the following code:
+class a
+{
+	protected class b
+	{
+	}
+}
+
+class c : a
+{
+	b a_var;
+	
+	protected class d
+	{
+		b d_var;
+	}
+}
+
+Actual Results:
+MCS says error CS0122, 'a+b' in inaccessible, at the d_var definition (not
+the a_var). CSC says OK.
+
+Expected Results:
+MCS behaves as CSC.
+
+How often does this happen? 
+always
+
+Additional Information:
+Detected while trying to port FlexWiki to mono. Currently, prevents
+FlexWiki from compiling on mono.