This is a live mirror of the Perl 5 development currently hosted at
https://github.com/perl/perl5
https://perl5.git.perl.org
/
perl5.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
01602aa
)
Dump empty-string ENAMEs as empty strings
author
Father Chrysostomos
<sprout@cpan.org>
Sun, 15 May 2016 17:59:18 +0000
(10:59 -0700)
committer
Father Chrysostomos
<sprout@cpan.org>
Sun, 15 May 2016 21:01:28 +0000
(14:01 -0700)
They were coming out as ‘(null)’, which is incorrect and confusing.
dump.c
patch
|
blob
|
blame
|
history
diff --git
a/dump.c
b/dump.c
index
c1303b6
..
8e11546
100644
(file)
--- a/
dump.c
+++ b/
dump.c
@@
-1818,7
+1818,7
@@
Perl_do_sv_dump(pTHX_ I32 level, PerlIO *file, SV *sv, I32 nest, I32 maxnest, bo
HEK *const *const endp = HvAUX(sv)->xhv_name_u.xhvnameu_names
+ (count < 0 ? -count : count);
while (hekp < endp) {
- if (
HEK_LEN(*hekp)
) {
+ if (
*hekp
) {
SV *tmp = newSVpvs_flags("", SVs_TEMP);
Perl_sv_catpvf(aTHX_ names, ", \"%s\"",
generic_pv_escape(tmp, HEK_KEY(*hekp), HEK_LEN(*hekp), HEK_UTF8(*hekp)));