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

[perl #111462] refcount warnings from C<use strict> C<our %FIELDS>

Thread Previous | Thread Next
From:
Father Chrysostomos via RT
Date:
April 3, 2012 08:50
Subject:
[perl #111462] refcount warnings from C<use strict> C<our %FIELDS>
Message ID:
rt-3.6.HEAD-4610-1333468200-1568.111462-15-0@perl.org
On Sat Mar 31 17:06:21 2012, sprout wrote:
> On Sat Mar 31 13:23:15 2012, sprout wrote:
> > For now, I’m simply going to restore the amount of warnings to the 5.14
> > level by moving the new strict hints from %^H into $^H.
> 
> With this approach, B::Concise’s tests have to be adjusted, and maybe
> B::Concise itself.  How should it render those hints?  Right now, in my
> working copy (and in the sprout/111462 branch), it spits out 3758096384,
> and changing the tests to look for that just seems icky.  It also seems
> like a regression for B::Concise’s output to be much less readable.
> 
> So I propose using $$ && ** for the ‘explicit strict’ hints, ($ & *
> being used already for regular strict hints).  But I am concerned that
> each of those has a completely different meaning in Perl when doubled
> up, so the mnemonic may be obscured too much.  So maybe x$ x& and x*.

I’ve used the latter suggestion and pushed the changes as d1718a7.

The unbalanced string table warnings are now back to the 5.14 level, so
Safe no longer triggers them in those cases cited.  However, the
underlying problem is still present, as we still get a warning in this case:

$ PERL_DESTRUCT_LEVEL=1 ./perl -Ilib -MSafe -e
'Safe->new->reval(q(BEGIN{$^H{foo}=bar}use strict))'
Unbalanced string table refcount: (1) for "foo" during global destruction.

This ticket should probably still stay open, but it no longer needs to
block 5.16.

-- 

Father Chrysostomos


---
via perlbug:  queue: perl5 status: open
https://rt.perl.org:443/rt3/Ticket/Display.html?id=111462

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