|
Posted by szr on March 21, 2008, 12:02 am
Please log in for more thread options
PerlFAQ Server wrote:
> This is an excerpt from the latest version perlfaq7.pod, which
> comes with the standard Perl distribution. These postings aim to
> reduce the number of repeated questions as well as allow the community
> to review and update the answers. The latest version of the complete
> perlfaq is at http://faq.perl.org .
>
> --------------------------------------------------------------------
>
> 7.3: Do I always/never have to quote my strings or use semicolons and
> commas?
>
> Normally, a bareword doesn't need to be quoted, but in most cases
> probably should be (and must be under "use strict"). But a hash key
> consisting of a simple word (that isn't the name of a defined
> subroutine) and the left-hand operand to the "=>" operator both
> count as though they were quoted:
>
> This is like this
> ------------ ---------------
> $foo $foo
> bar => stuff 'bar' => stuff
Shouldn't this be:
bar => 'stuff' 'bar' => 'stuff'
?
Thanks again for the wonderful documentation you people have put a lot
of time into.
--
szr
|