in reply to When numeric conversion overloading goes awry.
The bug is that 0+ should always return something that is a number. Undef, as you've discovered, isn't a number.-exists $self->{'-value'} ? $self->{'-value'} : undef; +exists $self->{'-value'} ? $self->{'-value'} : 0;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: When numeric conversion overloading goes awry.
by dmitri (Priest) on Jan 25, 2006 at 16:25 UTC | |
by dragonchild (Archbishop) on Jan 25, 2006 at 18:14 UTC |