This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Fix deparsing of subs named :::: and ::::::
authorFather Chrysostomos <sprout@cpan.org>
Sun, 22 May 2011 01:38:46 +0000 (18:38 -0700)
committerFather Chrysostomos <sprout@cpan.org>
Sun, 22 May 2011 01:38:46 +0000 (18:38 -0700)
commitd1dc589de16981f247132e8e7b3ecaa472913d8a
tree940ec5f9cc4f2a4e2769f2ce4b3011beb9dc4a63
parentbdabb2d5e95e614c681c9c1c6a410f5f0096a4f8
Fix deparsing of subs named :::: and ::::::

Since a name like :::: is now divided up as ::/:: (since commit
088225f), there can be a package called ‘::’. But %:: returns %main::,
not %main::::. The result is that the main package is searched again
and again recursively and stash_subs hangs.

The easiest fix is to put main:: at the beginning of a substash’s name
when fetching the stash.
dist/B-Deparse/Deparse.pm
dist/B-Deparse/t/deparse.t