[Mono-bugs] [Bug 35492][Nor] Changed - "error CS0205: Cannot call an abstract base indexer: object System.Collections.IList.get_Item" thown when no abstract classes involved.

bugzilla-daemon@rocky.ximian.com bugzilla-daemon@rocky.ximian.com
18 Dec 2002 18:18:36 -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 bryan@alphora.com.

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

--- shadow/35492	Wed Dec 18 13:16:27 2002
+++ shadow/35492.tmp.18107	Wed Dec 18 13:18:36 2002
@@ -77,6 +77,53 @@
 
 
 ------- Additional Comments From bryan@alphora.com  2002-12-18 13:16 -------
 Created an attachment (id=3008)
 Much simpler test case
 
+
+------- Additional Comments From bryan@alphora.com  2002-12-18 13:18 -------
+using System;
+using System.IO;
+using System.Reflection;
+using System.Collections;
+using System.ComponentModel;
+
+namespace Alphora.Dataphor
+{
+	public class DisposableNotifyList : ArrayList
+	{
+	}
+	
+public class ChildList : DisposableNotifyList
+    {
+		public new Object this[int AIndex]
+		{
+			get
+			{
+				return (Object)(base[AIndex]);
+			}
+			set
+			{
+				base[AIndex] = value;
+			}
+		}
+        
+        public Object this[string AIndex]
+        {
+            get
+            {
+                int LIndex = IndexOf(AIndex);
+                return this[LIndex];
+            }
+            set
+            {
+                base[IndexOf(AIndex)] = value;
+            }
+        }
+    }
+}
+
+
+
+If you set ChildList to desend directly from ArrayList, the error 
+goes away.  Code compiles and works fine under mcs.