diff options
author | Nick Ing-Simmons <nik@tiuk.ti.com> | 1998-12-05 16:14:42 +0000 |
---|---|---|
committer | Nick Ing-Simmons <nik@tiuk.ti.com> | 1998-12-05 16:14:42 +0000 |
commit | 0cc1d052f2b5aa0a485e4a60aabe91829ddbe78c (patch) | |
tree | b4979327e0d5279d1ca64dcbac71db825e46eaef /ext/B/B.pm | |
parent | cf86991c04b212c029b30807ecab507b784fd8ad (diff) | |
download | perl-0cc1d052f2b5aa0a485e4a60aabe91829ddbe78c.tar.gz |
Avoid hard-coding op numbers
Update CC.pm to save %INC, and to co-exist with new C.pm
p4raw-id: //depot/perl@2453
Diffstat (limited to 'ext/B/B.pm')
-rw-r--r-- | ext/B/B.pm | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/ext/B/B.pm b/ext/B/B.pm index 75dcfb3b74..1599fe21c5 100644 --- a/ext/B/B.pm +++ b/ext/B/B.pm @@ -11,7 +11,7 @@ require Exporter; @ISA = qw(Exporter DynaLoader); @EXPORT_OK = qw(byteload_fh byteload_string minus_c ppname class peekop cast_I32 cstring cchar hash threadsv_names - main_root main_start main_cv svref_2object + main_root main_start main_cv svref_2object opnumber walkoptree walkoptree_slow walkoptree_exec walksymtable parents comppadlist sv_undef compile_stats timing_info init_av); @@ -187,9 +187,12 @@ sub walkoptree_exec { sub walksymtable { my ($symref, $method, $recurse, $prefix) = @_; my $sym; + my $ref; no strict 'vars'; local(*glob); - while (($sym, *glob) = each %$symref) { + $prefix = '' unless defined $prefix; + while (($sym, $ref) = each %$symref) { + *glob = $ref; if ($sym =~ /::$/) { $sym = $prefix . $sym; if ($sym ne "main::" && &$recurse($sym)) { |