Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation
 
PerlMonks  

Re: Recursive directories

by Jenda (Abbot)
on Apr 02, 2014 at 12:08 UTC ( #1080761=note: print w/ replies, xml ) Need Help??


in reply to Recursive directories

Drop the File::Path->.

The point is that you are calling the make_path() as if it was a static/class method, while it's an ordinary, non-OO subroutine. When you write Foo->bar(...), Perl not only looks for subroutine named "bar" in the package "Foo" and its parent packages, but also passes the "Foo" to the bar() subroutine as the first parameter.

Assuming the Foo package contains a bar() subroutine

Foo->bar('hello');
is thus equivalent to
Foo::bar( 'Foo', 'hello');

Jenda
Enoch was right!
Enjoy the last years of Rome.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others lurking in the Monastery: (8)
As of 2016-06-27 23:24 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    My preferred method of making French fries (chips) is in a ...











    Results (348 votes). Check out past polls.