📄 b.3
字号:
value regardless of whether it's stored signed orunsigned..IP "needs64bits" 4.IX Item "needs64bits".PD 0.IP "packiv" 4.IX Item "packiv".PD.Sh "B::NV Methods".IX Subsection "B::NV Methods".IP "\s-1NV\s0" 4.IX Item "NV".PD 0.IP "\s-1NVX\s0" 4.IX Item "NVX".PD.Sh "B::RV Methods".IX Subsection "B::RV Methods".IP "\s-1RV\s0" 4.IX Item "RV".Sh "B::PV Methods".IX Subsection "B::PV Methods".PD 0.IP "\s-1PV\s0" 4.IX Item "PV".PDThis method is the one you usually want. It constructs astring using the length and offset information in the struct:for ordinary scalars it will return the string that you'd seefrom Perl, even if it contains null characters..IP "\s-1RV\s0" 4.IX Item "RV"Same as B::RV::RV, except that it will \fIdie()\fR if the \s-1PV\s0 isn'ta reference..IP "\s-1PVX\s0" 4.IX Item "PVX"This method is less often useful. It assumes that the stringstored in the struct is null-terminated, and disregards thelength information..SpIt is the appropriate method to use if you need to get the nameof a lexical variable from a padname array. Lexical variable namesare always stored with a null terminator, and the length field(SvCUR) is overloaded for other purposes and can't be relied on here..Sh "B::PVMG Methods".IX Subsection "B::PVMG Methods".IP "\s-1MAGIC\s0" 4.IX Item "MAGIC".PD 0.IP "SvSTASH" 4.IX Item "SvSTASH".PD.Sh "B::MAGIC Methods".IX Subsection "B::MAGIC Methods".IP "\s-1MOREMAGIC\s0" 4.IX Item "MOREMAGIC".PD 0.IP "precomp" 4.IX Item "precomp".PDOnly valid on r\-magic, returns the string that generated the regexp..IP "\s-1PRIVATE\s0" 4.IX Item "PRIVATE".PD 0.IP "\s-1TYPE\s0" 4.IX Item "TYPE".IP "\s-1FLAGS\s0" 4.IX Item "FLAGS".IP "\s-1OBJ\s0" 4.IX Item "OBJ".PDWill \fIdie()\fR if called on r\-magic..IP "\s-1PTR\s0" 4.IX Item "PTR".PD 0.IP "\s-1REGEX\s0" 4.IX Item "REGEX".PDOnly valid on r\-magic, returns the integer value of the \s-1REGEX\s0 storedin the \s-1MAGIC\s0..Sh "B::PVLV Methods".IX Subsection "B::PVLV Methods".IP "\s-1TARGOFF\s0" 4.IX Item "TARGOFF".PD 0.IP "\s-1TARGLEN\s0" 4.IX Item "TARGLEN".IP "\s-1TYPE\s0" 4.IX Item "TYPE".IP "\s-1TARG\s0" 4.IX Item "TARG".PD.Sh "B::BM Methods".IX Subsection "B::BM Methods".IP "\s-1USEFUL\s0" 4.IX Item "USEFUL".PD 0.IP "\s-1PREVIOUS\s0" 4.IX Item "PREVIOUS".IP "\s-1RARE\s0" 4.IX Item "RARE".IP "\s-1TABLE\s0" 4.IX Item "TABLE".PD.Sh "B::GV Methods".IX Subsection "B::GV Methods".IP "is_empty" 4.IX Item "is_empty"This method returns \s-1TRUE\s0 if the \s-1GP\s0 field of the \s-1GV\s0 is \s-1NULL\s0..IP "\s-1NAME\s0" 4.IX Item "NAME".PD 0.IP "\s-1SAFENAME\s0" 4.IX Item "SAFENAME".PDThis method returns the name of the glob, but if the firstcharacter of the name is a control character, then it convertsit to ^X first, so that *^G would return \*(L"^G\*(R" rather than \*(L"\ecG\*(R"..SpIt's useful if you want to print out the name of a variable.If you restrict yourself to globs which exist at compile-timethen the result ought to be unambiguous, because code like\&\f(CW\*(C`${"^G"} = 1\*(C'\fR is compiled as two ops \- a constant string anda dereference (rv2gv) \- so that the glob is created at runtime..SpIf you're working with globs at runtime, and need to disambiguate*^G from *{\*(L"^G\*(R"}, then you should use the raw \s-1NAME\s0 method..IP "\s-1STASH\s0" 4.IX Item "STASH".PD 0.IP "\s-1SV\s0" 4.IX Item "SV".IP "\s-1IO\s0" 4.IX Item "IO".IP "\s-1FORM\s0" 4.IX Item "FORM".IP "\s-1AV\s0" 4.IX Item "AV".IP "\s-1HV\s0" 4.IX Item "HV".IP "\s-1EGV\s0" 4.IX Item "EGV".IP "\s-1CV\s0" 4.IX Item "CV".IP "\s-1CVGEN\s0" 4.IX Item "CVGEN".IP "\s-1LINE\s0" 4.IX Item "LINE".IP "\s-1FILE\s0" 4.IX Item "FILE".IP "\s-1FILEGV\s0" 4.IX Item "FILEGV".IP "GvREFCNT" 4.IX Item "GvREFCNT".IP "\s-1FLAGS\s0" 4.IX Item "FLAGS".PD.Sh "B::IO Methods".IX Subsection "B::IO Methods".IP "\s-1LINES\s0" 4.IX Item "LINES".PD 0.IP "\s-1PAGE\s0" 4.IX Item "PAGE".IP "\s-1PAGE_LEN\s0" 4.IX Item "PAGE_LEN".IP "\s-1LINES_LEFT\s0" 4.IX Item "LINES_LEFT".IP "\s-1TOP_NAME\s0" 4.IX Item "TOP_NAME".IP "\s-1TOP_GV\s0" 4.IX Item "TOP_GV".IP "\s-1FMT_NAME\s0" 4.IX Item "FMT_NAME".IP "\s-1FMT_GV\s0" 4.IX Item "FMT_GV".IP "\s-1BOTTOM_NAME\s0" 4.IX Item "BOTTOM_NAME".IP "\s-1BOTTOM_GV\s0" 4.IX Item "BOTTOM_GV".IP "\s-1SUBPROCESS\s0" 4.IX Item "SUBPROCESS".IP "IoTYPE" 4.IX Item "IoTYPE".IP "IoFLAGS" 4.IX Item "IoFLAGS".IP "IsSTD" 4.IX Item "IsSTD".PDTakes one arguments ( 'stdin' | 'stdout' | 'stderr' ) and returns trueif the IoIFP of the object is equal to the handle whose name waspassed as argument ( i.e. \f(CW$io\fR\->IsSTD('stderr') is true ifIoIFP($io) == \fIPerlIO_stdin()\fR )..Sh "B::AV Methods".IX Subsection "B::AV Methods".IP "\s-1FILL\s0" 4.IX Item "FILL".PD 0.IP "\s-1MAX\s0" 4.IX Item "MAX".IP "\s-1ARRAY\s0" 4.IX Item "ARRAY".IP "ARRAYelt" 4.IX Item "ARRAYelt".PDLike \f(CW\*(C`ARRAY\*(C'\fR, but takes an index as an argument to get only one element,rather than a list of all of them..IP "\s-1OFF\s0" 4.IX Item "OFF"This method is deprecated if running under Perl 5.8, and is no longer presentif running under Perl 5.9.IP "AvFLAGS" 4.IX Item "AvFLAGS"This method returns the \s-1AV\s0 specific flags. In Perl 5.9 these are now storedin with the main \s-1SV\s0 flags, so this method is no longer present..Sh "B::CV Methods".IX Subsection "B::CV Methods".IP "\s-1STASH\s0" 4.IX Item "STASH".PD 0.IP "\s-1START\s0" 4.IX Item "START".IP "\s-1ROOT\s0" 4.IX Item "ROOT".IP "\s-1GV\s0" 4.IX Item "GV".IP "\s-1FILE\s0" 4.IX Item "FILE".IP "\s-1DEPTH\s0" 4.IX Item "DEPTH".IP "\s-1PADLIST\s0" 4.IX Item "PADLIST".IP "\s-1OUTSIDE\s0" 4.IX Item "OUTSIDE".IP "\s-1OUTSIDE_SEQ\s0" 4.IX Item "OUTSIDE_SEQ".IP "\s-1XSUB\s0" 4.IX Item "XSUB".IP "\s-1XSUBANY\s0" 4.IX Item "XSUBANY".PDFor constant subroutines, returns the constant \s-1SV\s0 returned by the subroutine..IP "CvFLAGS" 4.IX Item "CvFLAGS".PD 0.IP "const_sv" 4.IX Item "const_sv".PD.Sh "B::HV Methods".IX Subsection "B::HV Methods".IP "\s-1FILL\s0" 4.IX Item "FILL".PD 0.IP "\s-1MAX\s0" 4.IX Item "MAX".IP "\s-1KEYS\s0" 4.IX Item "KEYS".IP "\s-1RITER\s0" 4.IX Item "RITER".IP "\s-1NAME\s0" 4.IX Item "NAME".IP "\s-1ARRAY\s0" 4.IX Item "ARRAY".IP "\s-1PMROOT\s0" 4.IX Item "PMROOT".PDThis method is not present if running under Perl 5.9, as the \s-1PMROOT\s0information is no longer stored directly in the hash..Sh "OP-RELATED \s-1CLASSES\s0".IX Subsection "OP-RELATED CLASSES"\&\f(CW\*(C`B::OP\*(C'\fR, \f(CW\*(C`B::UNOP\*(C'\fR, \f(CW\*(C`B::BINOP\*(C'\fR, \f(CW\*(C`B::LOGOP\*(C'\fR, \f(CW\*(C`B::LISTOP\*(C'\fR, \f(CW\*(C`B::PMOP\*(C'\fR,\&\f(CW\*(C`B::SVOP\*(C'\fR, \f(CW\*(C`B::PADOP\*(C'\fR, \f(CW\*(C`B::PVOP\*(C'\fR, \f(CW\*(C`B::LOOP\*(C'\fR, \f(CW\*(C`B::COP\*(C'\fR..PPThese classes correspond in the obvious way to the underlying Cstructures of similar names. The inheritance hierarchy mimics theunderlying C \*(L"inheritance\*(R":.PP.Vb 10\& B::OP\& |\& +\-\-\-\-\-\-\-\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-\-+\-\-\-\-\-\-\-+\& | | | | |\& B::UNOP B::SVOP B::PADOP B::COP B::PVOP\& ,\*(Aq \`\-.\& / \`\-\-.\& B::BINOP B::LOGOP\& |\& |\& B::LISTOP\& ,\*(Aq \`.\& / \e\& B::LOOP B::PMOP.Ve.PPAccess methods correspond to the underlying C structre field names,with the leading \*(L"class indication\*(R" prefix (\f(CW"op_"\fR) removed..Sh "B::OP Methods".IX Subsection "B::OP Methods"These methods get the values of similarly named fields within the \s-1OP\s0data structure. See top of \f(CW\*(C`op.h\*(C'\fR for more info..IP "next" 4.IX Item "next".PD 0.IP "sibling" 4.IX Item "sibling".IP "name" 4.IX Item "name".PDThis returns the op name as a string (e.g. \*(L"add\*(R", \*(L"rv2av\*(R")..IP "ppaddr" 4.IX Item "ppaddr"This returns the function name as a string (e.g. \*(L"PL_ppaddr[\s-1OP_ADD\s0]\*(R",\&\*(L"PL_ppaddr[\s-1OP_RV2AV\s0]\*(R")..IP "desc" 4.IX Item "desc"This returns the op description from the global C PL_op_desc array(e.g. \*(L"addition\*(R" \*(L"array deref\*(R")..IP "targ" 4.IX Item "targ".PD 0.IP "type" 4.IX Item "type".IP "opt" 4.IX Item "opt".IP "flags" 4.IX Item "flags".IP "private" 4.IX Item "private".IP "spare" 4.IX Item "spare".PD.Sh "B::UNOP \s-1METHOD\s0".IX Subsection "B::UNOP METHOD".IP "first" 4.IX Item "first".Sh "B::BINOP \s-1METHOD\s0".IX Subsection "B::BINOP METHOD".PD 0.IP "last" 4.IX Item "last".PD.Sh "B::LOGOP \s-1METHOD\s0".IX Subsection "B::LOGOP METHOD".IP "other" 4.IX Item "other".Sh "B::LISTOP \s-1METHOD\s0".IX Subsection "B::LISTOP METHOD".PD 0.IP "children" 4.IX Item "children".PD.Sh "B::PMOP Methods".IX Subsection "B::PMOP Methods".IP "pmreplroot" 4.IX Item "pmreplroot".PD 0.IP "pmreplstart" 4.IX Item "pmreplstart".IP "pmnext" 4.IX Item "pmnext".IP "pmregexp" 4.IX Item "pmregexp".IP "pmflags" 4.IX Item "pmflags".IP "extflags" 4.IX Item "extflags".IP "precomp" 4.IX Item "precomp".IP "pmoffset" 4.IX Item "pmoffset".PDOnly when perl was compiled with ithreads..Sh "B::SVOP \s-1METHOD\s0".IX Subsection "B::SVOP METHOD".IP "sv" 4.IX Item "sv".PD 0.IP "gv" 4.IX Item "gv".PD.Sh "B::PADOP \s-1METHOD\s0".IX Subsection "B::PADOP METHOD".IP "padix" 4.IX Item "padix".Sh "B::PVOP \s-1METHOD\s0".IX Subsection "B::PVOP METHOD".PD 0.IP "pv" 4.IX Item "pv".PD.Sh "B::LOOP Methods".IX Subsection "B::LOOP Methods".IP "redoop" 4.IX Item "redoop".PD 0.IP "nextop" 4.IX Item "nextop".IP "lastop" 4.IX Item "lastop".PD.Sh "B::COP Methods".IX Subsection "B::COP Methods".IP "label" 4.IX Item "label".PD 0.IP "stash" 4.IX Item "stash".IP "stashpv" 4.IX Item "stashpv".IP "file" 4.IX Item "file".IP "cop_seq" 4.IX Item "cop_seq".IP "arybase" 4.IX Item "arybase".IP "line" 4.IX Item "line".IP "warnings" 4.IX Item "warnings".IP "io" 4.IX Item "io".IP "hints" 4.IX Item "hints".IP "hints_hash" 4.IX Item "hints_hash".PD.SH "AUTHOR".IX Header "AUTHOR"Malcolm Beattie, \f(CW\*(C`mbeattie@sable.ox.ac.uk\*(C'\fR
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -