Make FalseClass behave like TrueClass with meta programming
- by Edvinas Bartkus
This is theoretical question: is it possible to change FalseClass behavior to act like TrueClass?
It is possible to override to_s, xor, &, | behavior but that is not enough.
If you like Test Driven Development, follow my colleague's suggestion:
puts "false is new true!" if false
puts "never happens" if true
Asserts won't work, would it?
Is it possible to pass the test successfully?