Beefy Boxes and Bandwidth Generously Provided by pair Networks
Syntactic Confectionery Delight
 
PerlMonks  

Re: scalars in parens ?

by lidden (Curate)
on Apr 23, 2006 at 19:45 UTC ( [id://545153] : note . print w/replies, xml ) Need Help??


in reply to scalars in parens ?

Context, with parens you assign to a list. It does not matter in your case, but:
my $foo = 'bah' =~ /(a)/; print "$foo\n"; ($foo) = 'bah' =~ /(a)/; print "$foo\n";