This queue is for tickets about the NEXT CPAN distribution.

Report information
The Basics
Id:
40730
Status:
resolved
Priority:
Low/Low
Queue:

People
Owner:
Nobody in particular
Requestors:
mods [...] hank.org
Cc:
AdminCc:

BugTracker
Severity:
Normal
Broken in:
0.60
Fixed in:
(no value)



Subject: Perl 5.10 warnings: "<symbol> used only once: possible typo at /usr/share/perl/5.10/NEXT.pm line 58."
Perl 5.10 complains about used only once symbols a lot more, so this module becomes very noisy when running make test (global warnings enabled). Attached is a patch. (I noticed I have 0.60_01 -- don't remember where that came from, but the patch is trivial to apply manually).
Subject: NEXT.5.10.patch
--- NEXT.orig 2008-11-06 11:56:40.000000000 -0800 +++ NEXT.pm 2008-11-06 11:57:15.000000000 -0800 @@ -1,8 +1,9 @@ package NEXT; -$VERSION = '0.60_01'; +$VERSION = '0.60_02'; use Carp; use strict; + sub NEXT::ELSEWHERE::ancestors { my @inlist = shift; @@ -54,12 +55,24 @@ last if shift @forebears eq $caller_class } no strict 'refs'; - @{$NEXT::NEXT{$self,$wanted_method}} = - map { *{"${_}::$caller_method"}{CODE}||() } @forebears - unless $wanted_method eq 'AUTOLOAD'; - @{$NEXT::NEXT{$self,$wanted_method}} = - map { (*{"${_}::AUTOLOAD"}{CODE}) ? "${_}::AUTOLOAD" : ()} @forebears - unless @{$NEXT::NEXT{$self,$wanted_method}||[]}; + + unless ( $wanted_method eq 'AUTOLOAD' ) { + @{$NEXT::NEXT{$self,$wanted_method}} = + map { *{"${_}::$caller_method"}{CODE}||() } @forebears; + + # Suppress "used only once" warnings + ${"${_}::$caller_method"} = undef for @forebears; + } + + + unless ( @{$NEXT::NEXT{$self,$wanted_method}||[]} ) { + @{$NEXT::NEXT{$self,$wanted_method}} = + map { (*{"${_}::AUTOLOAD"}{CODE}) ? "${_}::AUTOLOAD" : ()} @forebears; + + # Suppress "used only once" warnings + ${"${_}::AUTOLOAD"} = undef for @forebears; + } + $NEXT::SEEN->{$self,*{$caller}{CODE}}++; } my $call_method = shift @{$NEXT::NEXT{$self,$wanted_method}};
Please have a look at the once_warning branch at git://github.com/rafl/next.git and let me know if it fixes things for you.
Fixed in 0.62.


This service runs on Request Tracker, is sponsored by The Perl Foundation, and maintained by Best Practical Solutions.

Please report any issues with rt.cpan.org to rt-cpan-admin@bestpractical.com.