summaryrefslogtreecommitdiff
path: root/dump.c
diff options
context:
space:
mode:
authorDavid Mitchell <davem@iabyn.com>2016-11-12 11:21:43 +0000
committerDavid Mitchell <davem@iabyn.com>2016-11-12 16:15:09 +0000
commite08d24ff56cda24d8146e29d00376eb23eedbd7e (patch)
tree21f1d566bdccb1130f744bdc1c4e4b2699c05a88 /dump.c
parente068d7ce00d1fee2864b3a347fc5eb1f6bfd6250 (diff)
downloadperl-e08d24ff56cda24d8146e29d00376eb23eedbd7e.tar.gz
Only test SvTAIL when SvVALID
Only use the SvTAIL() macro when we've already confirmed that the SV is SvVALID() - this is in preparation for removing the SVpbm_TAIL flag in the next commit
Diffstat (limited to 'dump.c')
-rw-r--r--dump.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/dump.c b/dump.c
index 5b59500952..49a03a5738 100644
--- a/dump.c
+++ b/dump.c
@@ -1513,8 +1513,11 @@ Perl_do_sv_dump(pTHX_ I32 level, PerlIO *file, SV *sv, I32 nest, I32 maxnest, bo
if (SvIsUV(sv) && !(flags & SVf_ROK)) sv_catpv(d, "IsUV,");
break;
case SVt_PVMG:
- if (SvTAIL(sv)) sv_catpv(d, "TAIL,");
- if (SvVALID(sv)) sv_catpv(d, "VALID,");
+ if (SvVALID(sv)) {
+ sv_catpv(d, "VALID,");
+ if (SvTAIL(sv))
+ sv_catpv(d, "TAIL,");
+ }
goto do_uv;
case SVt_PVAV:
break;