SPUG: Too long to find bug: Fat comma and assignment look similar, and have some similar meaning
Michael R. Wolf
MichaelRWolf at att.net
Thu Jan 14 11:59:58 PST 2010
On Jan 14, 2010, at 11:50 AM, Charles DeRykus wrote:
> I can't think of good use for fat/skinny comma in that context but
> maybe a more devious mind is needed..
>
> It does seem odd that rand (srand too) don't warn since other
> arithmetic functions do:
>
> perl -wle 'my $x => sin'
> Useless use of sin in void context ...
> Use of uninitialized value $_ in sin ...
>
> and similiar warnings for cos, exp, int, log ..
And similar warnings for other bare words...
my $x => my_func; # Warning
my $x => my_func(); # No warning
--
Michael R. Wolf
All mammals learn by playing!
MichaelRWolf at att.net
More information about the spug-list
mailing list