Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re: GetOpt::Long usage style

by Abigail-II (Bishop)
on Mar 08, 2003 at 23:00 UTC ( #241453=note: print w/ replies, xml ) Need Help??


in reply to Re: GetOpt::Long usage style
in thread GetOpt::Long usage style

This is also easy:
(my $verbose='');
This is an empty list (or better, a list containing that particular piece of emptiness referenced by $verbose.

You might call it easy, but it's wrong. Twice. First of all, parenthesis do NOT make lists. Context makes lists. Parenthesis are used for precedence.
Furthermore, if the context would demand a list (which in this case it does), it's not an empty list. How could it be? There's a scalar inside it. It's a one element list.

Abigail


Comment on Re: GetOpt::Long usage style
Download Code
Re: Re: GetOpt::Long usage style
by robartes (Priest) on Mar 08, 2003 at 23:22 UTC
    Goes to show again that I feel perfectly comfortable with my foot in my mouth. Thanks for the heads up, demerpq, zby and Abigail-II!

    CU
    Robartes-

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://241453]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others making s'mores by the fire in the courtyard of the Monastery: (13)
As of 2014-12-19 14:44 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    Is guessing a good strategy for surviving in the IT business?





    Results (84 votes), past polls