Beefy Boxes and Bandwidth Generously Provided by pair Networks
The stupid question is the question not asked
 
PerlMonks  

Re: Perl globbing syntax with $variables?

by toolic (Bishop)
on Aug 01, 2012 at 20:23 UTC ( #984890=note: print w/ replies, xml ) Need Help??


in reply to Perl globbing syntax with $variables?

B::Deparse (Tip #6 from the Basic debugging checklist) shows that <> in your 1st example is indeed a glob, but <> in the 2nd example is not a glob:

1st:

use File::Glob (); use warnings; @FILES = glob('//server/path/WantedFiles*.*'); foreach $file (@FILES) { (); }

2nd:

$WantedFiles = '//server/path/WantedFiles*.*'; @FILES = <$WantedFiles>; foreach $file (@FILES) { (); }

I/O Operators


Comment on Re: Perl globbing syntax with $variables?
Select or Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others musing on the Monastery: (19)
As of 2015-07-02 17:46 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (44 votes), past polls