Why can't I call an extension method from a base class of the extended type?
I'm trying add the ability to lookup elements in a List<KeyValuePair<string,int>> by overriding the indexer. using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.Threading.Tasks; namespace ConsoleApplication2 { public class MyList : List<KeyValuePair<string, int>> { public int this[string key] { get { return base.Single(item => item.Key == key).Value; } } } } For some reason, the compiler is throwing this error: ' System.Collections.Generic.List<System.Collections.Generic.KeyValuePair<string,int>> ' does not contain a definition for ' Single '.