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

Re: sub Issue include

by Stevie-O (Friar)
on Dec 17, 2004 at 20:56 UTC ( #415773=note: print w/ replies, xml ) Need Help??

in reply to sub Issue include

What do you mean, 'your sub just includes another file'?

Do you mean it reads a file into memory, and you want to reread that file every time in the subroutine? If so, that's easy. Just move the code that reads the file into your sub.

Or do you mean it loads a *module*? If that's the case, you need to do a little more work. You need to tell Perl to forget that it's loaded the module, and then re-use the module;

sub foo { delete $INC{'My/Cool/'); no warnings 'redefined'; require My::Cool::Module; # etc. etc. etc. }

And if it's neither of those things, I have no idea what you're trying to do.

$"=$,,$_=q>|\p4<6 8p<M/_|<('=> .q>.<4-KI<l|2$<6%s!<qn#F<>;$, .=pack'N*',"@{[unpack'C*',$_] }"for split/</;$_=$,,y[A-Z a-z] {}cd;print lc

Comment on Re: sub Issue include
Select or Download Code
Replies are listed 'Best First'.
Re^2: sub Issue include
by Anonymous Monk on Dec 17, 2004 at 20:56 UTC
    No its just another perl script.
      You're being exceedingly brief here.

      Please paste some actual code so that we may understand just what it is you're doing.

      $"=$,,$_=q>|\p4<6 8p<M/_|<('=> .q>.<4-KI<l|2$<6%s!<qn#F<>;$, .=pack'N*',"@{[unpack'C*',$_] }"for split/</;$_=$,,y[A-Z a-z] {}cd;print lc

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (3)
As of 2015-10-08 23:49 GMT
Find Nodes?
    Voting Booth?

    Does Humor Belong in Programming?

    Results (232 votes), past polls