« blib/lib/DTL/Fast/Tag/Templatetag.pm
↑ Summary
blib/lib/DTL/Fast/Expression/Operator/Unary/Defined.pm »
| 1 | package DTL::Fast::Expression::Operator::Unary::Not; | ||||||||||
| 2 | 5 | ▶ | use strict; use utf8; use warnings FATAL => 'all'; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
Subroutine
BEGIN: called CC=1 SCAR=0.0
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 3 | 5 | ▶ | use parent 'DTL::Fast::Expression::Operator::Unary::Logical'; | ||||||||
|
Subroutine
BEGIN: called CC=1 SCAR=0.0
| |||||||||||
| 4 | |||||||||||
| 5 | 5 | $DTL::Fast::OPS_HANDLERS{'not'} = __PACKAGE__; | |||||||||
| 6 | |||||||||||
| 7 | sub dispatch | ||||||||||
| 8 | { | ||||||||||
| 9 | 922 | ▶ | my( $self, $arg1) = @_; | ||||||||
|
Subroutine
dispatch: called CC=2 SCAR=7.4
Pod
undocumented
| |||||||||||
| 10 | 922 | my $arg1_type = ref $arg1; | |||||||||
| 11 | |||||||||||
| 12 | 922 | ▶ | if( UNIVERSAL::can($arg1, 'not')) | ||||||||
|
Branch: 1 branch
| |||||||||||
| 13 | { | ||||||||||
| 14 | 0 | return $arg1->not(); | |||||||||
| 15 | } | ||||||||||
| 16 | else | ||||||||||
| 17 | { | ||||||||||
| 18 | 922 | return !$arg1; | |||||||||
| 19 | } | ||||||||||
| 20 | } | ||||||||||
| 21 | |||||||||||
| 22 | 5 | 1; | |||||||||