Skip Menu |

This queue is for tickets about the Scalar-List-Utils CPAN distribution.

Report information
The Basics
Id: 97033
Status: new
Priority: 0/
Queue: Scalar-List-Utils

Owner: Nobody in particular
Requestors: djerius [...]
Cc: ether [...]

Bug Information
Severity: Normal
Broken in: 1.39
Fixed in: (no value)

Subject: Attempt to free unreferenced scalar when used with Package::Stash
Download (untitled) / with headers
text/plain 821b
Perl is throwing a "free unreferenced scalar" error when pairmap is used in conjunction with Package::Stash (0.36). I'm not sure which package is at fault, but the error is thrown at a line number after the pairgrep invocation (not within it), so I'm guessing(!) it might by Package::Stash. Here's the failing code: use Package::Stash; use List::Util 'pairmap'; my $m = Package::Stash->new('main'); my %h = ( a => 1, b => 2 ); pairmap { $m->add_symbol( '$'. $a, $b ) } %h; print $a; and here are the results when run under either 5.16.3 or 5.20.0: Attempt to free unreferenced scalar: SV 0x13bc5e0, Perl interpreter: 0x1347010 at line 14. Attempt to free unreferenced scalar: SV 0x1368f18, Perl interpreter: 0x1347010. A simple loop over the hash rather than using pairmap works fine. Thanks, Diab

This service is sponsored and maintained by Best Practical Solutions and runs on infrastructure.

Please report any issues with to