Bug #11976
Updated by nobu (Nobuyoshi Nakada) almost 9 years ago
When assigning to nil as a hash, the RHS gets short-circuited, and the hash assignment on nil returns nil. To reproduce: ~~~ruby ~~~ nil[:some_key] = undefined_method # Expected: NameError: undefined local variable or method `undefined_method' for main:Object # Actual: evaluates to nil. No errors raised. ~~~