On Thu Sep 29 00:04:29 2011, ostmann@websuche.de wrote: > Attached pure-perl script produce on all tested versions following > glibc error: > > *** glibc detected *** /home/websuche/perl5lib/bin/perl: > munmap_chunk(): invalid pointer: 0x0000000000f72c48 *** > > > TESTED VERSIONS: > 5.8.8 > 5.10.0 > 5.10.1 > 5.14.0 > 5.14.1 > > > SKRIPT: > #!/usr/bin/env perl > > *guard::DESTROY = sub { > ${$_[0]}->(); > }; > > *guard = sub (&) { > my $callback = shift; > return bless \$callback, "guard" > }; > > my %t; %t = ( > stash => { > guard => guard(sub{ > print "Guard\n"; > delete $t{stash}; > }), > foo => "bar", > bar => "baz", > }, > ); > > delete $t{stash}{guard}; This has been fixed with commit 3b2cd80. If you need to work around it on older perls, call delete in non-void context: () = delete $t{stash}{guard}; -- Father Chrysostomos --- via perlbug: queue: perl5 status: open https://rt.perl.org:443/rt3/Ticket/Display.html?id=100340