BEGIN {
eval { require Config };
die 'OS unsupported' if $@;
- Config->import(qw/%Config/);
+ Config->import(qw<%Config>);
eval { require File::Spec };
die 'OS unsupported' if $@;
}
my $sess = eval {
Test::Valgrind::Session->new(
min_version => $tool->requires_version,
- map { $_ => delete $args{$_} } qw/extra_supps no_def_supp/
+ map { $_ => delete $args{$_} } qw<extra_supps no_def_supp>
);
};
unless ($sess) {
=cut
-use base qw/Test::Valgrind::Component Test::Valgrind::Carp/;
+use base qw<Test::Valgrind::Component Test::Valgrind::Carp>;
=head1 METHODS
use File::Spec ();
-use base qw/Test::Valgrind::Carp/;
+use base qw<Test::Valgrind::Carp>;
=head1 METHODS
=cut
-use base qw/Test::Valgrind::Action Test::Valgrind::Action::Captor/;
+use base qw<Test::Valgrind::Action Test::Valgrind::Action::Captor>;
=head1 METHODS
my %validated;
- for (qw/name target/) {
+ for (qw<name target>) {
my $arg = delete $args{$_};
$class->_croak("'$_' is expected to be a plain scalar")
unless $arg and not ref $arg;
my $self = $class->SUPER::new(%args);
- $self->{$_} = $validated{$_} for qw/name target/;
+ $self->{$_} = $validated{$_} for qw<name target>;
$self;
}
$self->SUPER::start($sess);
- delete @{$self}{qw/status supps diagnostics/};
+ delete @{$self}{qw<status supps diagnostics>};
$self->save_fh(\*STDOUT => '>' => undef);
$self->save_fh(\*STDERR => '>' => undef);
use Test::Builder;
-use base qw/Test::Valgrind::Action Test::Valgrind::Action::Captor/;
+use base qw<Test::Valgrind::Action Test::Valgrind::Action::Captor>;
=head1 METHODS
seek $fh, $self->{capture_pos}, 0;
$tb->diag($_) while <$fh>;
close $fh or $self->_croak('close(capture[' . fileno($fh) . "]): $!");
- delete @{$self}{qw/capture capture_pos/};
+ delete @{$self}{qw<capture capture_pos>};
}
my $failed = 0;
=cut
-use base qw/Test::Valgrind::Carp/;
+use base qw<Test::Valgrind::Carp>;
=head1 METHODS
use Scalar::Util ();
-use base qw/Test::Valgrind::Command Test::Valgrind::Carp/;
+use base qw<Test::Valgrind::Command Test::Valgrind::Carp>;
=head1 METHODS
use Test::Valgrind::Suppressions;
-use base qw/Test::Valgrind::Command Test::Valgrind::Carp/;
+use base qw<Test::Valgrind::Command Test::Valgrind::Carp>;
=head1 METHODS
{
package Test::Valgrind::Test::Fake;
- use base qw/strict/;
+ use base qw<strict>;
}
-eval 'use Time::HiRes qw/usleep/';
+eval 'use Time::HiRes qw<usleep>';
=cut
-use base qw/Test::Valgrind::Command::Perl Test::Valgrind::Carp/;
+use base qw<Test::Valgrind::Command::Perl Test::Valgrind::Carp>;
=head1 METHODS
use Scalar::Util ();
-use base qw/Test::Valgrind::Carp/;
+use base qw<Test::Valgrind::Carp>;
=head1 METHODS
=cut
-use base qw/Test::Valgrind::Component Test::Valgrind::Carp/;
+use base qw<Test::Valgrind::Component Test::Valgrind::Carp>;
=head1 METHODS
use Test::Valgrind::Suppressions;
-use base qw/Test::Valgrind::Parser::Text Test::Valgrind::Carp/;
+use base qw<Test::Valgrind::Parser::Text Test::Valgrind::Carp>;
=head1 METHODS
my %call; # Frames to append (if the value is 1) or to prepend (if it's 0)
if ($t eq 'm') { # malloc can also be called by calloc or realloc
- $call{$_} = 1 for qw/calloc realloc/;
+ $call{$_} = 1 for qw<calloc realloc>;
} elsif ($t eq 're') { # realloc can also call malloc or free
- $call{$_} = 0 for qw/malloc free/;
+ $call{$_} = 0 for qw<malloc free>;
} elsif ($t eq 'c') { # calloc can also call malloc
- $call{$_} = 0 for qw/malloc/;
+ $call{$_} = 0 for qw<malloc>;
}
my $c = $_;
package Test::Valgrind::Report::Suppressions;
-use base qw/Test::Valgrind::Report/;
+use base qw<Test::Valgrind::Report>;
sub kinds { shift->SUPER::kinds(), 'Suppression' }
=cut
-use base qw/Test::Valgrind::Parser/;
+use base qw<Test::Valgrind::Parser>;
=head1 METHODS
=cut
-use base qw/Test::Valgrind::Parser/;
+use base qw<Test::Valgrind::Parser>;
=head1 METHODS
use Scalar::Util ();
-use base qw/Test::Valgrind::Parser::XML Test::Valgrind::Carp XML::Twig/;
+use base qw<Test::Valgrind::Parser::XML Test::Valgrind::Carp XML::Twig>;
BEGIN { XML::Twig->add_options('Stash'); }
=cut
eval "sub $_ { \@_ <= 1 ? \$_[0]->{$_} : (\$_[0]->{$_} = \$_[1]) }"
- for qw/_session protocol_version/;
+ for qw<_session protocol_version>;
# We must store the session in ourselves because it's only possible to pass
# arguments to XML::Twig objects by a global stash.
$data->{stack} = [ map $_->listify_frame,
$node->kid('stack')->children('frame') ];
- for (qw/leakedbytes leakedblocks/) {
+ for (qw<leakedbytes leakedblocks>) {
my $kid = ($xwhat || $node)->first_child($_);
next unless $kid;
$data->{$_} = int $kid->text;
BEGIN { require XML::Twig; }
-use base qw/XML::Twig::Elt Test::Valgrind::Carp/;
+use base qw<XML::Twig::Elt Test::Valgrind::Carp>;
sub kid {
my ($self, $what) = @_;
map {
my $x = $frame->first_child($_);
$x ? $x->text : undef
- } qw/ip obj fn dir file line/
+ } qw<ip obj fn dir file line>
];
}
=cut
-use base qw/Test::Valgrind::Carp/;
+use base qw<Test::Valgrind::Carp>;
=head2 C<< new kind => $kind, id => $id, data => $data >>
use version ();
-use base qw/Test::Valgrind::Carp/;
+use base qw<Test::Valgrind::Carp>;
=head1 METHODS
=cut
-eval "sub $_ { \$_[0]->{$_} }" for qw/valgrind no_def_supp/;
+eval "sub $_ { \$_[0]->{$_} }" for qw<valgrind no_def_supp>;
=head2 C<extra_supps>
my @members;
BEGIN {
- @members = qw/action tool command parser/;
+ @members = qw<action tool command parser>;
for (@members) {
eval "sub $_ { \@_ <= 1 ? \$_[0]->{$_} : (\$_[0]->{$_} = \$_[1]) }";
die if $@;
my %args = @_;
- for (qw/action tool command/) {
+ for (qw<action tool command>) {
my $base = 'Test::Valgrind::' . ucfirst;
my $value = $args{$_};
$self->_croak("Invalid $_") unless Scalar::Util::blessed($value)
$self->$_($args{$_})
}
- delete @{$self}{qw/last_status exit_code/};
+ delete @{$self}{qw<last_status exit_code>};
$self->tool->start($self);
$self->parser($self->parser_class->new)->start($self);
return unless defined $report;
- for my $handler (qw/tool command/) {
+ for my $handler (qw<tool command>) {
$report = $self->$handler->filter($self, $report);
return unless defined $report;
}
=cut
-use base qw/Test::Valgrind::Carp/;
+use base qw<Test::Valgrind::Carp>;
=head1 METHODS
=cut
-use base qw/Test::Valgrind::Component Test::Valgrind::Carp/;
+use base qw<Test::Valgrind::Component Test::Valgrind::Carp>;
=head1 METHODS
=cut
-use base qw/Test::Valgrind::Tool/;
+use base qw<Test::Valgrind::Tool>;
=head1 METHODS
package Test::Valgrind::Tool::memcheck::Report;
-use base qw/Test::Valgrind::Report/;
+use base qw<Test::Valgrind::Report>;
our $VERSION = '1.12';
-my @kinds = qw/
+my @kinds = qw<
InvalidFree
MismatchedFree
InvalidRead
Leak_IndirectlyLost
Leak_PossiblyLost
Leak_StillReachable
-/;
+>;
push @kinds, __PACKAGE__->SUPER::kinds();
my %kinds_hashed = map { $_ => 1 } @kinds;
{
package Test::Valgrind::Test::Fake;
- use base qw/strict/;
+ use base qw<strict>;
}
plan tests => 1;
pod_coverage_ok('Test::Valgrind::Parser::XML', $trustparents);
pod_coverage_ok('Test::Valgrind::Parser::XML::Twig', {
%$trustparents,
- also_private => [ qr/^handle_/, qw/stash/ ],
+ also_private => [ qr/^handle_/, qw<stash> ],
});
pod_coverage_ok('Test::Valgrind::Report');
use strict;
use warnings;
-use base qw/Test::Valgrind::Action::Test/;
+use base qw<Test::Valgrind::Action::Test>;
my $extra_tests;