Argument Checking
Last week Brad Abrams in
Why can't NullReferenceException tell you the type of the instance that was null? remarked "
the .NET Framework and WinFX generally do argument checking on all publicly exposed APIs" and then asked "
… Are they worth it?".
Absolutely - the small performance cost, saves me from far bigger problems on a regular basis. In addition its inspired our team to use arg checks throughout our code. They've never been a performance problem for us < 1% our time is spent doing arg checks.