internally perl interpreter reads any file and runs an eval() on the content and if eval status returns true then the file is *compiled*.

Since normal scripts have a number of statements which we use in the void context but which return true so we never have to do an return true in normal scripts
But when a module is compiled there are no statements to run so in order to satisfy a return true condition we write 1; ( you could write anything 10; or print ""; or anything that returns true )


Jeff Westman wrote:
I usually see the last line in a package as

   1;

Does this force the package to compile without error?  What does it do,
and why don't all packages have it?


Thanks


JW

__________________________________________________
Do you Yahoo!?
Yahoo! Mail Plus - Powerful. Affordable. Sign up now.
http://mailplus.yahoo.com

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to