[Mono-bugs] [Bug 66615][Min] New - Incorrect CS0108 wrt. indexers

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Wed, 22 Sep 2004 14:24:34 -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 martin@ximian.com.

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

--- shadow/66615	2004-09-22 14:24:34.000000000 -0400
+++ shadow/66615.tmp.19521	2004-09-22 14:24:34.000000000 -0400
@@ -0,0 +1,51 @@
+Bug#: 66615
+Product: Mono: Compilers
+Version: unspecified
+OS: 
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Minor
+Component: C#
+AssignedTo: mono-bugs@ximian.com                            
+ReportedBy: martin@ximian.com               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: Incorrect CS0108 wrt. indexers
+
+When compiling the following testcase
+
+====
+using System;
+
+public class Foo
+{
+        public long this [int start, int count] {
+                set {
+                }
+        }
+}
+
+public class Bar : Foo
+{
+        public virtual long this [int i] {
+                set {
+                }
+        }
+}
+
+class X
+{
+        static void Main ()
+        { }
+}
+====
+
+MCS reports an incorrect CS0108:
+
+B.cs(13) warning CS0108: The keyword new is required on
+'Bar.this[System.Int32]' because it hides inherited member
+B.cs(5): 'Foo.this[int]' (name of symbol related to previous warning)