Re: Strange problem with glob <>
- From: igor.sutton@xxxxxxxxx ("Igor Sutton")
- Date: Thu, 28 Dec 2006 08:41:06 +0000
Hi Madhur,
2006/12/28, Madhur Kashyap <physiologoius@xxxxxxxxx>:
Hi there,
Have a look at these two different implementations. IMPL2 works somehow.
The
problem I am facing is that the glob <$pat> does not return any value in
IMPL1 but it returns in IMPL2. Can somebody tell what could be the
problem.
I have also tried including the advanced glob module using
use File::Glob qw(:globally :case);
[snip]
First of all, I'd like to suggest you activate strict and warnings pragma.
It will help you to catch any mistakes you did. Another suggestion is using
the Getopt::Std or Getopt::Long modules, instead of writing your own
argument parser.
For resolving your file search problem, I suggest the File::Find or
File::Find::Rule modules instead. glob can give you headaches, and it
doesn't support regexes, just shell like substitution.
HTH
--
Igor Sutton Lopes <igor.sutton@xxxxxxxxx>
- References:
- Strange problem with glob <>
- From: "Madhur Kashyap"
- Strange problem with glob <>
- Prev by Date: Re: HoA building
- Next by Date: Re: HoA building
- Previous by thread: Strange problem with glob <>
- Next by thread: Re: Strange problem with glob <>
- Index(es):
Relevant Pages
|