in reply to my least favorite perl feature
What is "overloaded" by design in perl is two possible values for every scalar: a string or a number. The comparison operators let you choose which. Do you want to give up either lexical or numeric sorting by overloading "<=>"?
By the way, if you "use warnings" perl will help you out, like so:
Argument "bbb" isn't numeric in numeric eq (==) at ddd.pl line 4.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Re: my least favorite perl feature
by waxmop (Beadle) on Feb 05, 2003 at 21:30 UTC | |
by chromatic (Archbishop) on Feb 05, 2003 at 21:49 UTC |
In Section
Seekers of Perl Wisdom