In lisp, nil is the empty set, and can be enumerated in the standard
In ObjC, and, I believe, Smalltalk, nil swallows all messages and
This is /exceedingly/ useful in writing very small amounts of code, and
I am highly irritated that ruby didn’t get this right, because it leads
to tons and tons of small error checks that are otherwise un-needed.
“Catches more errors” isn’t supposed to be the answer in the ruby
idiom, it’s just another case of relying on static type checks instead
of proper testing, which is exactly what we’re not supposed to be
doing, right? Otherwise we’d all be using java because rigid typing
“catches more errors”.
I would love for ruby’s nil to behave properly, as it does in lisp and
objc. You can ask nil anything, but all you’re going to get back is nil.