static class Extensions {
public static IEnumerable<TSource> WhereKey<TSource >(
this SortedDictionary<KeyWrapper, TSource> source,
string key) {

yield return source[new KeyWrapper(key)];
}
}

static void DemoSortedListTrace() {
SortedDictionary<KeyWrapper, string> list = new
	SortedDictionary<KeyWrapper, string>();

for (char ch = 'Z'; ch >= 'A'; ch--) {
	list.Add(new KeyWrapper(ch.ToString()), "Psmeno " + ch.ToString());
}

Console.WriteLine("-- queryStandard --");
var queryStandard =
from l in list
where l.Key.Value == "M"
select l.Value;
Dump(queryStandard);

Console.WriteLine("-- queryFast --");
var queryFast = list.WhereKey("M");
Dump(queryFast);
}
