diff options
author | Father Chrysostomos <sprout@cpan.org> | 2014-09-22 22:09:34 -0700 |
---|---|---|
committer | Father Chrysostomos <sprout@cpan.org> | 2014-09-23 05:52:01 -0700 |
commit | bb1efdce4c120f5570738ad0b7fe2c9b5a4b218b (patch) | |
tree | c48ba3091ba3e861f186d399fec063a93d2164e2 /ext/B | |
parent | ee2276e59a3c027cb89c721d866c9db4ba683a7b (diff) | |
download | perl-bb1efdce4c120f5570738ad0b7fe2c9b5a4b218b.tar.gz |
Add GPFLAGS and GPf_* to B
Diffstat (limited to 'ext/B')
-rw-r--r-- | ext/B/B.xs | 4 | ||||
-rw-r--r-- | ext/B/Makefile.PL | 2 | ||||
-rw-r--r-- | ext/B/t/b.t | 6 |
3 files changed, 11 insertions, 1 deletions
diff --git a/ext/B/B.xs b/ext/B/B.xs index 15cadafd78..bc423cc4af 100644 --- a/ext/B/B.xs +++ b/ext/B/B.xs @@ -1799,6 +1799,10 @@ U32 GvLINE(gv) B::GV gv +U32 +GvGPFLAGS(gv) + B::GV gv + void FILEGV(gv) B::GV gv diff --git a/ext/B/Makefile.PL b/ext/B/Makefile.PL index 308b015a31..81f6826897 100644 --- a/ext/B/Makefile.PL +++ b/ext/B/Makefile.PL @@ -30,7 +30,7 @@ my @names = ({ name => 'HEf_SVKEY', macro => 1, type => "IV" }, # match the pattern below. foreach my $tuple (['cop.h'], ['cv.h', 'CVf'], - ['gv.h', 'GVf'], + ['gv.h', 'G[PV]f'], ['op.h'], ['opcode.h', 'OPp'], ['op_reg_common.h','(?:(?:RXf_)?PMf_)'], diff --git a/ext/B/t/b.t b/ext/B/t/b.t index 271eb371ea..7bdd87cbac 100644 --- a/ext/B/t/b.t +++ b/ext/B/t/b.t @@ -203,6 +203,12 @@ is($gv_ref->SAFENAME(), "gv", "Test SAFENAME()"); like($gv_ref->FILE(), qr/b\.t$/, "Testing FILE()"); is($gv_ref->SvTYPE(), B::SVt_PVGV, "Test SvTYPE()"); is($gv_ref->FLAGS() & B::SVTYPEMASK, B::SVt_PVGV, "Test SVTYPEMASK"); +is($gv_ref->GPFLAGS & B::GPf_ALIASED_SV, 0, 'GPFLAGS are unset'); +{ + local *gv = \my $x; + is($gv_ref->GPFLAGS & B::GPf_ALIASED_SV, B::GPf_ALIASED_SV, + 'GPFLAGS gets GPf_ALIASED_SV set'); +} # The following return B::SPECIALs. is(ref B::sv_yes(), "B::SPECIAL", "B::sv_yes()"); |