Revision: 1325 Author: [email protected] Date: Thu Jul 8 03:48:58 2010 Log: Add flag to fileinfo_of to avoid warning on undef arg.
http://code.google.com/p/perl-devel-nytprof/source/detail?r=1325 Modified: /trunk/lib/Devel/NYTProf/Data.pm ======================================= --- /trunk/lib/Devel/NYTProf/Data.pm Wed Jul 7 10:05:28 2010 +++ /trunk/lib/Devel/NYTProf/Data.pm Thu Jul 8 03:48:58 2010 @@ -333,10 +333,10 @@ sub fileinfo_of { - my $self = shift; - my $arg = shift; + my ($self, $arg, $silent_if_undef) = @_; + if (not defined $arg) { - carp "Can't resolve fid of undef value"; + carp "Can't resolve fid of undef value" unless $silent_if_undef; return undef; } -- You've received this message because you are subscribed to the Devel::NYTProf Development User group. Group hosted at: http://groups.google.com/group/develnytprof-dev Project hosted at: http://perl-devel-nytprof.googlecode.com CPAN distribution: http://search.cpan.org/dist/Devel-NYTProf To post, email: [email protected] To unsubscribe, email: [email protected]
