Comment Re:Wouldn't help (Score 1) 612
But the point is that in a huge number of situations you wouldn't need to check it. Checking for it all the time is something like using static methods (in Java) and doing "if instanceof" checks on the arguments all the time. That's the job of polymorphism! So, having a custom null-object for every object type would save the client a very big proportion of null-checks -- read "null errors."
For example, one usually checks that a string is non-null and not empty; sums two Integers, always having to check BOTH for non-null; or, the most notorious of them all, just wants to see if two objects are equal. In all such examples the non-null check vanishes, resulting in code that is at the same time more elegant, more readable and more robust.