由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
Programming版 - perl beginner question "1;" ?
相关主题
perl eval and ifdouble free or corruption问题
请教各位先贤一个Perl 问题c++ exception 一问
请教perl的tainted和cgi::param()winsock error 10053
perl questionhelp!无法编译一个package
Quick Question about perl modulememory leak 问题
python/perl interesting questionHow to resolve "terminate called after throwing an instance of 'std::bad_alloc'???
a simple question for C++ class如何改变一个文件的UNIT?
how to program a shell extension请教perl 高手: 如何detect windows programm的Debug window
相关话题的讨论汇总
话题: perl话题: beginner话题: question话题: value话题: pm
进入Programming版参与讨论
1 (共1页)
c*****t
发帖数: 10738
1
在好些pm文件, 最后1句是
1;
请问这是作什么用的。 谢谢!
s*******k
发帖数: 12
2
The last real-code line of all .pm files to be a TRUE value:
1;
is necessary to make sure that the "require" (inside the
"use") doesn't abort.
HTH

【在 c*****t 的大作中提到】
: 在好些pm文件, 最后1句是
: 1;
: 请问这是作什么用的。 谢谢!

s*******k
发帖数: 12
3
A follow-up for your question:
in Perl, if no return|exit statements or the like are involved, a function
call usually returns the value of the last statement in its definition
scope.

【在 s*******k 的大作中提到】
: The last real-code line of all .pm files to be a TRUE value:
: 1;
: is necessary to make sure that the "require" (inside the
: "use") doesn't abort.
: HTH

1 (共1页)
进入Programming版参与讨论
相关主题
请教perl 高手: 如何detect windows programm的Debug windowQuick Question about perl module
一个比较模糊的问题python/perl interesting question
Re: 有pyclewn大牛吗?教教怎么用?a simple question for C++ class
有人发现最近valgrind有问题么?how to program a shell extension
perl eval and ifdouble free or corruption问题
请教各位先贤一个Perl 问题c++ exception 一问
请教perl的tainted和cgi::param()winsock error 10053
perl questionhelp!无法编译一个package
相关话题的讨论汇总
话题: perl话题: beginner话题: question话题: value话题: pm