Keep It Simple, Stupid | |
PerlMonks |
Re: Comma's and blocksby erroneousBollock (Curate) |
on Oct 04, 2007 at 06:05 UTC ( [id://642572]=note: print w/replies, xml ) | Need Help?? |
Why are the comma's excluded in some spots and not others?They're not excluded... you may have completely misunderstood some of the syntactic forms.
That's roughly equivalent to: except that map() and grep() play with $_ on your behalf. As for:
The second print statement is equivalent to .. unless you've called select() to change which is the default filehandle.
How does this work with your own prototypes and subroutines?Prototypes allow the Perl parser to apply (for your subs) the same parser tricks it employs on built-in functions (like push()).
Which perldoc covers this in depth?perlsyn, perlsub, perlfunc should do it. -David
In Section
Seekers of Perl Wisdom
|
|