2 ms·
I'll add to that - In what "normal langs" is this not a problem? What would a C or C++ programmer expect? Because my experience in those languages says "castin
by dalke 11y ago
I'll add to that - In what "normal langs" is this not a problem?
What would a C or C++ programmer expect? Because my experience in those languages says "casting" is a meaningless way to understand what's going on.
Perl doesn't have bareword true/falue values. Ruby doesn't use "casting", I think. That is, I think the idiomatic way to express this in Ruby is:
>> !!true.to_s
=> true
>> !!false.to_s
=> true