diff options
author | Nicholas Clark <nick@ccl4.org> | 2005-11-05 16:47:31 +0000 |
---|---|---|
committer | Nicholas Clark <nick@ccl4.org> | 2005-11-05 16:47:31 +0000 |
commit | edcc7c74ed376a449c95af027d10cdeb74f64de8 (patch) | |
tree | a9ef4441ec44da5b3c7568985b645fb64eb03523 /ext | |
parent | f3fe0ae60051c4c73dd9f21d0864f94a81c10245 (diff) | |
download | perl-edcc7c74ed376a449c95af027d10cdeb74f64de8.tar.gz |
Make the 5.9 changes to B conditional on perl version.
p4raw-id: //depot/perl@26019
Diffstat (limited to 'ext')
-rw-r--r-- | ext/B/B.pm | 17 | ||||
-rw-r--r-- | ext/B/B.xs | 29 |
2 files changed, 45 insertions, 1 deletions
diff --git a/ext/B/B.pm b/ext/B/B.pm index 2346ac0470..5b6c04e8a1 100644 --- a/ext/B/B.pm +++ b/ext/B/B.pm @@ -7,7 +7,7 @@ # package B; -our $VERSION = '1.09'; +our $VERSION = '1.10'; use XSLoader (); require Exporter; @@ -855,6 +855,16 @@ IoIFP($io) == PerlIO_stdin() ). Like C<ARRAY>, but takes an index as an argument to get only one element, rather than a list of all of them. +=item OFF + +This method is deprecated if running under Perl 5.8, and is no longer present +if running under Perl 5.9 + +=item AvFLAGS + +This method returns the AV specific flags. In Perl 5.9 these are now stored +in with the main SV flags, so this method is no longer present. + =back =head2 B::CV Methods @@ -907,6 +917,11 @@ For constant subroutines, returns the constant SV returned by the subroutine. =item ARRAY +=item PMROOT + +This method is not present if running under Perl 5.9, as the PMROOT +information is no longer stored directly in the hash. + =back =head2 OP-RELATED CLASSES diff --git a/ext/B/B.xs b/ext/B/B.xs index f9c8647b96..953f6be0eb 100644 --- a/ext/B/B.xs +++ b/ext/B/B.xs @@ -1563,6 +1563,17 @@ SSize_t AvMAX(av) B::AV av +#if PERL_VERSION < 9 + + +#define AvOFF(av) ((XPVAV*)SvANY(av))->xof_off + +IV +AvOFF(av) + B::AV av + +#endif + void AvARRAY(av) B::AV av @@ -1584,6 +1595,16 @@ AvARRAYelt(av, idx) else XPUSHs(make_sv_object(aTHX_ sv_newmortal(), NULL)); +#if PERL_VERSION < 9 + +MODULE = B PACKAGE = B::AV + +U8 +AvFLAGS(av) + B::AV av + +#endif + MODULE = B PACKAGE = B::FM PREFIX = Fm IV @@ -1682,6 +1703,14 @@ char * HvNAME(hv) B::HV hv +#if PERL_VERSION < 9 + +B::PMOP +HvPMROOT(hv) + B::HV hv + +#endif + void HvARRAY(hv) B::HV hv |