Re:Ask Matz: why the id of nil is 4?
by macournoyer on Thursday February 02, 2012 @03:54PM
(#3544418)
Since in Ruby false and nil are the only "falsish" values and everything else is true, their values has been chosen to make a boolean test as efficient as possible. See: https://github.com/ruby/ruby/blob/trunk/include/ruby/ruby.h#...
[ Parent
| on HN ]
There are no comments on this comment yet.