~~';
return $self->violation( $DESC, $EXPL, $elem );
}
1;
__END__
=encoding utf-8
=head1 NAME
Perl::Critic::Policy::Operators::ProhibitSmartmatch
- avoid using explicit smartmatching via C<~~
Smartmatch operator is considered experimental, see L<perlop/"Smartmatch Operator">.
if ($foo ~~ [ $bar ]) {
say 'No!';
}
=head1 AUTHOR
Jan Holcapek E<lt>holcapek@gmail.comE<gt>, wh
return
sort
map { $_->name }
grep { 'XML::XSS::Role::StyleAttribute' ~~ @{ $_->applied_traits } }
grep { $_->has_applied_traits }
map { $self->meta->get_a
gs
return $r1 eq $r2;
}
}
elsif( $ref1 eq $ref2 ) {
if ( $ref1 ~~ [qw(Regexp GLOB CODE)] ) {
return $r1 eq $r2;
}
elsif ( $ref1 eq 'ARRA
$ref1 eq 'HASH' ) {
return _equal_hashes( $r1, $r2 );
}
elsif ( $ref1 ~~ [qw(SCALAR REF)] ) {
return are_equal($$r1, $$r2);
}
else {
($r1, $r2) = @_;
# Hashes can't be equal unless their keys are equal.
return unless ( %$r1 ~~ %$r2 );
# Compare the equality of the values for each key.
foreach my $key (keys %$r1) {
$self->get($name)->set(%$attrs);
}
}
sub get {
my ( $self, $name ) = @_;
given ( $name ) {
when ( '#document' ) {
return $self->document;
}
die;
}
}
sub resolve {
my ( $self, $node ) = @_;
my $type = ref $node;
given ($type) {
when ('XML::LibXML::Document') {
return $self->document;
}
ts}->{$idcol} ) {
#@pk = $dman{ $id }->get_autoinc_primarykeys;
#if ($id ~~ @pk) {
if ( grep /^$idcol$/, @pk ) {
$log{ $id }->debug( $idcol, " no
alue undef" )
unless ( defined $v );
# if ( defined $v && ( $id ~~ @{$self->{dates_formatted}})){
if ( defined $v && defined $widgets{ $id }->{hdates
toms) }]);
}
sub opt_spp_atom {
my $atom = shift;
my ($name, $value) = flat($atom);
given ($name) {
when ('Spec') { return opt_spp_spec($value) }
when ('Group') { return op
($char));
}
sub opt_spp_escape_char {
my $str = shift;
my $char = last_char($str);
given ($char) {
when ('n') { return "\n" }
when ('r') { return "\r" }
when ('t') { retur
return cons('Nclass', estr($atoms));
}
sub opt_spp_catom {
my ($name, $value) = @_;
given ($name) {
when ('Cclass') { return opt_spp_cclass($value) }
when ('Range') { return op
p abs log sqrt int 0+ #;
# non-numeric ops:
# x . x= .= cmp lt le gt ge eq ne ^. ^.= ~. "" qr -X ~~
sub overload_handler {
my ($ref, $y, $swap, $op) = @_;
my $handle = handle($ref);
my
if($self->view('Excel'))
{
unless ($self->view('Excel')->{etp_config}->{INCLUDE_PATH} ~~ $template_path) {
push @{$self->view('Excel')->{etp_config}->{INCLUDE_PATH}}, $templat
>view('Excel')->{etp_engine} = 'TTAutoFilter';
unless ($self->view($tt_view)->include_path ~~ $template_path) {
push @{$self->view($tt_view)->include_path}, $template_path;
nfig = $self->config->{'View::Excel'};
unless ($excel_config->{etp_config}->{INCLUDE_PATH} ~~ $template_path) {
push @{$excel_config->{etp_config}->{INCLUDE_PATH}}, $template_path;
=head2 max()
Returns the node with the maximal key.
=head2 nth(INDEX)
Returns the node at the given (zero based) index, or undef if there is no node at that index. Negative indexes can be used, wit
top' => undef,
# 26: 'left' => undef
# 27: },
# 28: 'cell_coercion' => bless( {
~~ Skipped 142 lines ~~
#170: 'display_name' => 'Excel_date_164',
#171: '
r' )
# 05: }, 'ANONYMOUS_SHIRAS_MOOSE_CLASS_1' );
# 06: You did something wrong at ~~error_string (defined at ../../../../lib/Spreadsheet/Reader/ExcelXML/Error.pm line 43) line 13.
et_error(Spreadsheet::Reader::ExcelXML::Error=HASH(0x31e398), "You did something wrong") called at ~~ line 110
# 09: ANONYMOUS_SHIRAS_MOOSE_CLASS_1::set_error(ANONYMOUS_SHIRAS_MOOSE_CLASS_1=HAS
lename=>'/etc/passwd');
};
# syntax for Perl >= 5.10
use feature 'switch';
if ($@) {
given (my $e = Exception::Base->catch) {
when ($e->isa('Exception::IO')) { warn "IO problem"; }
'} = 'to_string';
=item "~~"
Smart matching operator. See C<matches> method.
eval { Exception::Base->throw( message=>"Message", value=>123 ) };
print "Message" ~~ $@;
# 1
print ['Exception::Base'] ~~ $@; # 1
print 123 ~~ $@; # 1
print {message=>"Message", value=>123} ~~ $@; # 1
Warning: The smart operato
e;
# for my $mod (@{ $self->lump_module }) {
# push @lump_mods, $mod unless $mod ~~ @lump_mods;
# }
#}
# lump_dist
{
last unless $self->lump_dist;
es->[0] == 200;
for my $mod (@{$res->[2]}) {
push @lump_mods, $mod unless $mod ~~ @lump_mods;
}
}
# lump_dist_and_deps
{
last unless $self->lump_dist_a
lude_author && @{ $self->include_author }) {
last DECIDE unless $rec->{author} ~~ @{ $self->include_author };
}
$lump = 1;
}
begins with C<foo>), an empty array should
be returned. When an unknown user or unknown path is given (e.g. C<!paths
/var/zzz/*> when there is no directory named C</var/zzz/>) or there is an error
du
t void *buffer, png_int_32 row_stride,
const void *colormap));
/* Write the image to the given (FILE*). */
/* With both write APIs if image is in one of the linear formats with 16-bit
* d
he value of a 2D Gaussian function with mean 0
and standard deviation sig at the given (x,y) point.
!*/
// ---------------------------------------------------------------------
|^$rep_tmp/||;
my $rep = dirname $repfic;
my $fic = basename $repfic;
return 0 if $fic ~~ @exclusions_fic;
my $archive = ($fic =~ /\.(gz|tar|tgz|zip|bz2|tbz2|7z)$/);
my @stat
ntree, $md5);
}
}
}
# fin si repertoire exclu
return $err if $fic ~~ @exclusions_rep;
# repertoire
$err = $self->parcourir_repertoire($entree, $volume) if S_I
if no request has been made.
=cut
sub get_status {
my $self = shift;
my $answer;
given ( $self->get_raw_status ) {
$answer = undef when 0;
$answer = 1 when 200;
urrent tag
$result .= $tag->{pre}; # add in the intervening text
given ($tag->{type})
{
when('!') { # it's a comment
} elsif (scalar @ret == 1) {
$txt = $ret[0];
} else {
$txt = \@ret;
}
}
given (reftype $txt)
{
when ('ARRAY') { # an array of hashes (ho
# get the entry from the context
}
my $ans = '';
given (reftype $txt)
{
when ('ARRAY') {
$an
]} @e;
}
# create proxy functions
for my $e (@e) {
next if @$inc && !($e->[0] ~~ @$inc);
# get metadata if not yet retrieved
unless ($e->[2]) {
$res =