In perl.git, the branch blead has been updated <https://perl5.git.perl.org/perl.git/commitdiff/6fbf0c3106e14fed2b6901c567fbb10716895f10?hp=f65cb320dfb0701e599232a87aa5fa6a69d79a29>
- Log ----------------------------------------------------------------- commit 6fbf0c3106e14fed2b6901c567fbb10716895f10 Author: Father Chrysostomos <spr...@cpan.org> Date: Thu Oct 19 21:35:51 2017 -0700 Deparse.t tweak The revert two commits ago causes B::Deparse to go through a different code path when dumping the constant. Ideally the output should be the same either way (i.e., consistently with or without a semicolon, not sometimes one way and sometimes the other). But for now, just make the test more lenient. commit 834e1dc686d615ac888f5ddc4c85c14addd6c2b5 Author: Father Chrysostomos <spr...@cpan.org> Date: Thu Oct 19 20:14:29 2017 -0700 perldelta for 14062320f commit 6eed25e2537643b77650cb3e4514ec9dc2e97d74 Author: Father Chrysostomos <spr...@cpan.org> Date: Thu Oct 19 18:18:37 2017 -0700 Temporarily revert CV-in-stash optimisation This reverts two hunks from 6881372e19 to allow CPAN modules some time to conform to the optimisation. ----------------------------------------------------------------------- Summary of changes: lib/B/Deparse.t | 2 +- op.c | 2 +- pod/perldelta.pod | 7 +++++++ t/op/sub.t | 1 + 4 files changed, 10 insertions(+), 2 deletions(-) diff --git a/lib/B/Deparse.t b/lib/B/Deparse.t index c61cfa2f66..f1aae49fcb 100644 --- a/lib/B/Deparse.t +++ b/lib/B/Deparse.t @@ -162,7 +162,7 @@ $a = readpipe qq|$^X $path "-MO=Deparse"| .qq| -e "#line 123 four-five-six"| .qq| -e "package G; sub g(){0} sub s{}" 2>&1|; $a =~ s/-e syntax OK\n//g; -like($a, qr/sub F::f \(\) \{\s*0;\s*}/, +like($a, qr/sub F::f \(\) \{\s*0;?\s*}/, "Constant is dumped in package in which other subs are dumped"); unlike($a, qr/sub g/, "Constant is not dumped in package in which other subs are not dumped"); diff --git a/op.c b/op.c index 4e45800876..95b7971a9c 100644 --- a/op.c +++ b/op.c @@ -8596,7 +8596,7 @@ Perl_newATTRSUB_x(pTHX_ I32 floor, OP *o, OP *proto, OP *attrs, sub is stored in. */ const I32 flags = ec ? GV_NOADD_NOINIT - : (IN_PERL_RUNTIME && PL_curstash != CopSTASH(PL_curcop)) + : PL_curstash != CopSTASH(PL_curcop) || memchr(name, ':', namlen) || memchr(name, '\'', namlen) ? gv_fetch_flags : GV_ADDMULTI | GV_NOINIT | GV_NOTQUAL; diff --git a/pod/perldelta.pod b/pod/perldelta.pod index d93050733f..fc4c834bdc 100644 --- a/pod/perldelta.pod +++ b/pod/perldelta.pod @@ -368,6 +368,13 @@ has been fixed. This should call C<execvp()> with an empty C<argv> array returning false (and not setting L<C<$!>|perlvar/$!>). L<[perl #131730]|https://rt.perl.org/Public/Bug/Display.html?id=131730> +=item * + +The C<gv_fetchmeth_sv> C function stopped working properly in Perl 5.22 +when fetching a constant with a UTF-8 name if that constant subroutine was +stored in the stash as a simple scalar reference, rather than a full +typeglob. This has been corrected. + =back =head1 Known Problems diff --git a/t/op/sub.t b/t/op/sub.t index f73abb455f..5c501b181e 100644 --- a/t/op/sub.t +++ b/t/op/sub.t @@ -423,6 +423,7 @@ is ref($main::{rt_129916}), 'CODE', 'simple sub stored as CV in stash (main::)'; sub foo { 42 } } { + local $TODO = "CV symbol table optimization only works in main:: [perl #129916]"; is ref($RT129916::{foo}), 'CODE', 'simple sub stored as CV in stash (non-main::)'; } -- Perl5 Master Repository