Dear C# Architects
13 August 2007 15:01![[personal profile]](https://www.dreamwidth.org/img/silk/identity/user.png)
If I want to know if a given key is in a
In particular, I do not want you to throw an exception if I either
(a) attempt to retrieve a value for a key not in the dictionary, or
(b) attempt to set a value for a key in the dictionary.
Seriously. Not everything that might possibly be an error needs to result in throwing an exception (and had it occurred to you that I might want to _replace_ a value in the dictionary without the extra overhead of a call to
Your Somewhat Reluctant Disciple,
jrtom
PS: And get a decent collections API already, for [INSERT DEITY HERE]'s sake. Power Collections is a place to start, but by no means a place to finish...and it does not make up for many existing inadequacies.
Dictionary
, I'll do a Contains
check myself.In particular, I do not want you to throw an exception if I either
(a) attempt to retrieve a value for a key not in the dictionary, or
(b) attempt to set a value for a key in the dictionary.
Seriously. Not everything that might possibly be an error needs to result in throwing an exception (and had it occurred to you that I might want to _replace_ a value in the dictionary without the extra overhead of a call to
Remove()
?). Sheesh.Your Somewhat Reluctant Disciple,
![[livejournal.com profile]](https://www.dreamwidth.org/img/external/lj-userinfo.gif)
PS: And get a decent collections API already, for [INSERT DEITY HERE]'s sake. Power Collections is a place to start, but by no means a place to finish...and it does not make up for many existing inadequacies.