Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"

Re^2: stat a file

by pelos (Initiate)
on May 04, 2013 at 06:22 UTC ( #1031996=note: print w/replies, xml ) Need Help??

in reply to Re: stat a file
in thread stat a file

thanks I will give it a try. do you recommend to stick to one particular method? or doesn't really matter?

Replies are listed 'Best First'.
Re^3: stat a file
by afoken (Abbot) on May 04, 2013 at 09:30 UTC

    stat has slightly less overhead, but File::stat is slightly more readable. File::stat is part of the Perl core since 5.004 (released 1997-05-15), so it's quite safe to assume that File::stat is available even on older Perl installations.

    File::stat has some minor problems, mainly with the implicit $_ and the special handle _, see "Bugs" in File::stat. Also, the filetest operators -t, -T, and -B are not implemented in File::stat. This is documented in "Errors".


    Today I will gladly share my knowledge and experience, for there are no sweeter words than "I told you so". ;-)

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1031996]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (6)
As of 2018-06-23 14:40 GMT
Find Nodes?
    Voting Booth?
    Should cpanminus be part of the standard Perl release?

    Results (125 votes). Check out past polls.