I often come across code like the following:
if ( items != null) { foreach(T item in items) { //... } }
Basically, the
You could always test it out with a null list... but this is what I found on the msdn website
foreach-statement: foreach ( type identifier in expression ) embedded-statement
If expression has the value null, a System.NullReferenceException is thrown.