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 [EMAIL PROTECTED]

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

--- shadow/75412        2005-06-28 16:05:47.000000000 -0400
+++ shadow/75412.tmp.8803       2005-06-28 16:05:47.000000000 -0400
@@ -0,0 +1,38 @@
+Bug#: 75412
+Product: Mono: Compilers
+Version: 1.1
+OS: 
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Minor
+Component: C#
+AssignedTo: [EMAIL PROTECTED]                            
+ReportedBy: [EMAIL PROTECTED]               
+QAContact: [EMAIL PROTECTED]
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: indexers always treated as public
+
+If you define an indexer on a class, it is treated as public (or maybe
+internal?) regardless of its actual protection level.
+
+       using System;
+       
+       public class Foo {
+               private int this[int index] { get { return index; } }
+       }
+       
+       public class Bar {
+               public static void Main ()
+               {
+                       Foo foo = new Foo ();
+                       Console.WriteLine (foo[5]);
+               }
+       }
+
[EMAIL PROTECTED]:libstetic> mcs -out:/tmp/index.exe /tmp/index.cs
[EMAIL PROTECTED]:libstetic> mono /tmp/index.exe
+5
_______________________________________________
mono-bugs maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-bugs

Reply via email to