in reply to Re: Writing unix-style filters
in thread Writing unix-style filters
chomp( @files = @ARGV ? grep { -f $_ } @ARGV : <> );This chomps after you do the file test, with the newline not yet removed. So, it will just produce an empty array, when reading the file list from the input, because -f $_ will always return false.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Writing unix-style filters
by jdporter (Paladin) on Apr 11, 2007 at 15:38 UTC |