sv_dump should report the PV for PVGVs, as it can get set.
Nicholas Clark [Wed, 22 Feb 2006 18:21:30 +0000 (18:21 +0000)]
(Typeglobs stringify via a call to GET magic, which uses the PV slot.)

p4raw-id: //depot/perl@27269

dump.c
ext/Devel/Peek/t/Peek.t

diff --git a/dump.c b/dump.c
index 3057110..bf88590 100644 (file)
--- a/dump.c
+++ b/dump.c
@@ -1324,7 +1324,7 @@ Perl_do_sv_dump(pTHX_ I32 level, PerlIO *file, SV *sv, I32 nest, I32 maxnest, bo
        SvREFCNT_dec(d);
        return;
     }
-    if (type <= SVt_PVLV && type != SVt_PVGV) {
+    if (type <= SVt_PVLV) {
        if (SvPVX_const(sv)) {
            Perl_dump_indent(aTHX_ level, file,"  PV = 0x%"UVxf" ", PTR2UV(SvPVX_const(sv)));
            if (SvOOK(sv))
index 0f4fbb8..b8ee13a 100644 (file)
@@ -308,6 +308,7 @@ do_test(17,
   FLAGS = \\(GMG,SMG,MULTI(?:,IN_PAD)?\\)
   IV = 0
   NV = 0
+  PV = 0
   MAGIC = $ADDR
     MG_VIRTUAL = &PL_vtbl_glob
     MG_TYPE = PERL_MAGIC_glob\(\*\)