Beefy Boxes and Bandwidth Generously Provided by pair Networks
Do you know where your variables are?
 
PerlMonks  

Re: Re: Trying to load other perl scripts use() or require()

by dpuu (Chaplain)
on Jul 21, 2002 at 05:16 UTC ( [id://183781]=note: print w/replies, xml ) Need Help??


in reply to Re: Trying to load other perl scripts use() or require()
in thread Trying to load other perl scripts use() or require()

The value of any block in Perl is the result of the last statement in that block. If a block is a subroutine, then the result of the subroutine is the result of the block. You can use a "return" statement to exit the sub before the end; and at the end of the sub to be explicit about your intent. Modules are blocks. (Strangely, this doesn't apply to scripts: you have to use exit($value) to return a value from a script.) --Dave.
  • Comment on Re: Re: Trying to load other perl scripts use() or require()

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (5)
As of 2024-04-19 07:34 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found