develooper Front page | perl.perl5.porters | Postings from August 2012

Re: [perl #114372] Panic in pure-Perl code with vanilla perl-5.16.0from perlbrew

Thread Previous | Thread Next
From:
Dave Mitchell
Date:
August 2, 2012 05:14
Subject:
Re: [perl #114372] Panic in pure-Perl code with vanilla perl-5.16.0from perlbrew
Message ID:
20120802121419.GA2763@iabyn.com
On Wed, Aug 01, 2012 at 09:57:06PM +0200, Dennis Kaarsemaker wrote:
> Actually, the reverse seems unrelated (or I've uncovered another bug). I
> managed to reduce the testcase to: 
> 
> ./perl  -e '@x = (1,2); @h{@x=sort}=@x'

The sort's unrelated too. It can be reduced further to:

    @x = (1,2); @h{@x=()}=@x;

Looks like a classic stack-not-refcounted bug. The elements of @x are
pushed onto the stack, ready for the main assignment; then they are freed
by the @x=(), leaving freed elements on the stack.

-- 
"But Sidley Park is already a picture, and a most amiable picture too.
The slopes are green and gentle. The trees are companionably grouped at
intervals that show them to advantage. The rill is a serpentine ribbon
unwound from the lake peaceably contained by meadows on which the right
amount of sheep are tastefully arranged." -- Lady Croom, "Arcadia"

Thread Previous | Thread Next


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