On Thu, Sep 9, 2010 at 12:49, Jatin <daveyja...@gmail.com> wrote:
>
>> The callback is printing the value of $File::Find::name (which, again,
>> is set by the File::Find::find function before the callback is
>> called).
>>
>>
>>
>
> [Jatin] Chas , when you say that the File::Find's find method sets its name
> variable before the callback is called , Do you mean that this "name"
> variable is set by the find function to the currently referenced file or
> directory ? All the three variables namely $_ , $dir and $name are set with
> values corresponding to the currently referenced file ?
snip

Yes, if no_chdir is not set, then

$_ is the current file's name with no path
$File::Find::name is the current file's name with the path
$File::Find::dir is the path to the current file

You may want to read the [perldoc File::Find][0].

 [0]: http://perldoc.perl.org/File/Find.html#The-wanted-function

-- 
Chas. Owens
wonkden.net
The most important skill a programmer can have is the ability to read.

-- 
To unsubscribe, e-mail: beginners-unsubscr...@perl.org
For additional commands, e-mail: beginners-h...@perl.org
http://learn.perl.org/


Reply via email to