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:
8f1da26
)
Test require override with Deparse [perl #62500]
author
Father Chrysostomos
<sprout@cpan.org>
Sat, 21 May 2011 17:18:26 +0000
(10:18 -0700)
committer
Father Chrysostomos
<sprout@cpan.org>
Sat, 21 May 2011 17:18:51 +0000
(10:18 -0700)
dist/B-Deparse/t/deparse.t
patch
|
blob
|
blame
|
history
diff --git
a/dist/B-Deparse/t/deparse.t
b/dist/B-Deparse/t/deparse.t
index
802c31f
..
5ea240a
100644
(file)
--- a/
dist/B-Deparse/t/deparse.t
+++ b/
dist/B-Deparse/t/deparse.t
@@
-183,6
+183,19
@@
EOCODE
is $deparsed, $code, 'our $funny_Unicode_chars';
}
+# [perl #62500]
+$a =
+ `$^X $path "-MO=Deparse" -e "BEGIN{*CORE::GLOBAL::require=sub{1}}" 2>&1`;
+$a =~ s/-e syntax OK\n//g;
+is($a, <<'EOCODF', "CORE::GLOBAL::require override causing panick");
+sub BEGIN {
+ *CORE::GLOBAL::require = sub {
+ 1;
+ }
+ ;
+}
+EOCODF
+
done_testing();
__DATA__