I premise by saying that I would not use this. The new
keyword, while useful in this case, can create bugs which are really hard to find. Other than that, you can try this class.
class MyDictionary : Dictionary
{
public new TValue this[TKey key]
{
get
{
TValue value;
return TryGetValue(key, out value) ? value : default(TValue);
}
set { base[key] = value; }
}
}