develooper Front page | perl.perl5.porters | Postings from May 2010

[perl #8535] DProf interferes with @_ manipulation

Thread Previous
From:
Alexandr Ciornii via RT
Date:
May 11, 2010 12:13
Subject:
[perl #8535] DProf interferes with @_ manipulation
Message ID:
rt-3.6.HEAD-4976-1273605185-1309.8535-14-0@perl.org
Same results on 5.12.0. Also, Devel::Profile, Devel::DProfLB and
Devel::NYTProf do not modify result, only Devel::DProf.

On Thu Feb 14 10:01:13 2002, tim@srl.caltech.edu wrote:

> Subroutines meant to massage a callers @_ are prevented from doing so
> when instrumented with DProf. Thus:
> 
> % perl -le 'sub foo { shift; } sub bar { &foo; print "@_" } bar(1,2);'
> 2
> % perl -d:DProf -le 'sub foo { shift; } sub bar { &foo; print "@_" }
> bar(1,2);'
> 1 2
> 
> Runs normally under the debugger:
> 
> % perl -dle 'sub foo { shift; } sub bar { &foo; print "@_" }
> bar(1,2);'
> [blah blah blah]
>   DB<1> r
> 2

-- 
Alexandr Ciornii, http://chorny.net


Thread Previous


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About