Condition Coverage

blib/lib/SWF/Builder/ActionScript/Compiler.pm
Criterion Covered Total %
condition 48 320 15.0


and 3 conditions

line !l l&&!r l&&r condition
289 9 1 0 /\A0/ and s/\A(0[0-7]+)//i || s/\A(0x[0-9a-f]+)//i || s/\A(0b[01]+)//i
529 0 0 0 $$self{'stat'}{'Optimize'} & 32 && $$vars{$var}{'preload'}
0 0 0 $$vars{$var}{'count'} == 0 and not $$self{'stat'}{'Optimize'} & 32 && $$vars{$var}{'preload'}
542 0 0 0 exists $$vars{$var} and $$vars{$var}{'count'} >= 0
758 0 0 0 $$self{'stat'}{'Optimize'} & 2 and $e
0 0 0 $$self{'stat'}{'Optimize'} & 2 and $e and $e->isa('SWF::Builder::ActionScript::SyntaxNode::Literal')
782 0 0 0 $$self{'stat'}{'Optimize'} & 2 and $e
0 0 0 $$self{'stat'}{'Optimize'} & 2 and $e and $e->isa('SWF::Builder::ActionScript::SyntaxNode::Literal')
810 0 0 0 $$self{'stat'}{'Optimize'} & 2 and $e
0 0 0 $$self{'stat'}{'Optimize'} & 2 and $e and $e->isa('SWF::Builder::ActionScript::SyntaxNode::Literal')
867 0 0 0 defined $l and ref $$l{'node'}[-1] || ref $l
868 0 0 0 $$self{'stat'}{'Version'} <= 5 and /:Arguments$/
0 0 0 $$self{'stat'}{'Version'} <= 5 and /:Arguments$/ and $$l{'node'}[0]{'node'}[0] eq 'eval'
905 0 0 0 my $a1 = $self->assignment_expression and $self->_check_token(':')
0 0 0 my $a1 = $self->assignment_expression and $self->_check_token(':') and my $a2 = $self->assignment_expression
909 0 0 0 $$self{'stat'}{'Optimize'} & 2 and $e->isa('SWF::Builder::ActionScript::SyntaxNode::Literal')
973 0 0 1 not $f and $$self{'stat'}{'Optimize'} & 2
0 0 1 not $f and $$self{'stat'}{'Optimize'} & 2 and $e1->isa('SWF::Builder::ActionScript::SyntaxNode::Literal')
0 1 0 not $f and $$self{'stat'}{'Optimize'} & 2 and $e1->isa('SWF::Builder::ActionScript::SyntaxNode::Literal') and $e->isa('SWF::Builder::ActionScript::SyntaxNode::Literal') || $op[0] eq '&&' || $op[0] eq '||'
1036 0 0 0 $$self{'stat'}{'Optimize'} & 2 and $e->isa('SWF::Builder::ActionScript::SyntaxNode::Literal')
1125 0 0 1 @members == 0 and @methods == 0
0 0 1 @members == 0 and @methods == 0 and $$self{'stat'}{'Optimize'} & 4
1127 0 1 0 ref($name) =~ /:MemberExpression/ and lc $$name{'node'}[0]{'node'}[0] eq 'math'
1 0 0 ref($name) =~ /:MemberExpression/ and lc $$name{'node'}[0]{'node'}[0] eq 'math' and @{$$name{'node'};} == 2
1268 0 0 1 ref($tree[0]) =~ /:Variable/ and ref($tree[1]) =~ /:Member/
1288 0 0 0 $self->_check_token(']') && $n
1521 1 0 2 $value =~ /^-?\d+$/ and -2147483648 <= $value
1 0 2 $value =~ /^-?\d+$/ and -2147483648 <= $value and $value < 2147483648
1634 10 0 0 /^Not$/ and $$code[$p + 1] eq 'Not'
1640 4 6 0 /^Push / and $$code[$p + 1] eq 'Pop'
1651 10 0 0 /^Jump\s+'(.+)'/ and $$code[$p + 1] eq ":$1"
1657 10 0 0 /^Jump / and not $$code[$p + 1] =~ /^:/
1663 4 3 3 /^Push / and $$code[$p + 1] =~ /^Push /
1677 4 0 3 /^Push / and / String /
1799 0 0 0 $regvars and exists $$regvars{$var}
1800 0 0 0 defined $context and $context eq 'lvalue'
1817 0 0 0 $regvars and exists $$regvars{$var}
2138 0 0 0 $base < 0 and $exp != int $exp
2239 0 0 0 $term->isa('SWF::Builder::ActionScript::SyntaxNode::Infinity') and $$self{'node'}[0] ne $$term{'node'}[0]
2513 0 0 0 $regvars and exists $$regvars{$var}
2532 2 0 0 $regvars and exists $$regvars{$var}
2643 1 0 0 not $opt and $op ne '='
2747 0 0 0 $opt & 16 and not $opt & 32
0 0 0 $opt & 16 and not $opt & 32 and (my $regcount = $$self{'regvars'}{' regcount'}) > 0
2996 0 0 0 $context and $$node[0]
3032 0 0 0 $$stat{'Optimize'} & 16 and (my $regcount = $$self{'regvars'}{' regcount'}) > 0
3093 0 0 0 @$members == 0 && @$methods == 0
3122 0 0 0 lc $$name{'node'}[0] eq 'eval' and @$members == 0
0 0 0 lc $$name{'node'}[0] eq 'eval' and @$members == 0 and @$methods == 0
3191 0 0 0 $command->isa('SWF::Builder::ActionScript::SyntaxNode::Literal') and $param->isa('SWF::Builder::ActionScript::SyntaxNode::Literal')
3251 0 0 0 not $ext || defined $method and $url->isa('SWF::Builder::ActionScript::SyntaxNode::Literal')
0 0 0 not $ext || defined $method and $url->isa('SWF::Builder::ActionScript::SyntaxNode::Literal') and !defined($target) || $target->isa('SWF::Builder::ActionScript::SyntaxNode::Literal')
3739 0 0 0 $op eq '-' and $context
3741 0 0 0 $op ne '+' and $context
3773 0 0 0 ref($e) =~ /NumberLiteral$/ and $$e{'node'}[0] =~ /^\d+$/

or 2 conditions

line l !l condition
107 0 2 $actions || ''
121 0 0 $actions || ''
383 0 0 $_[2] || 'Syntax error'
964 36 4 $step ||= 0
1746 0 0 $indent ||= 0
3248 0 0 $fname || 'getURL'
3437 0 0 $scheme ||= 'print'

or 3 conditions

line l !l&&r !l&&!r condition
273 0 0 3 $reserved{$key} || (exists $property{lc $key} ? 'Property' : 'Identifier')
289 0 0 1 s/\A(0[0-7]+)//i || s/\A(0x[0-9a-f]+)//i || s/\A(0b[01]+)//i
331 1 0 0 $t eq 'Identifier' or $t eq 'Property'
1 0 0 $t eq 'Identifier' or $t eq 'Property' or $t eq 'Reserved'
559 0 2 2 $self->function_declaration || $self->statement
814 0 0 0 $else || $self->new_node('NullStatement')
867 0 0 0 ref $$l{'node'}[-1] || ref $l
868 0 0 0 /:Variable$/ or /:Property$/
0 0 0 /:Variable$/ or /:Property$/ or /:Member$/
0 0 0 /:Variable$/ or /:Property$/ or /:Member$/ or $$self{'stat'}{'Version'} <= 5 and /:Arguments$/ and $$l{'node'}[0]{'node'}[0] eq 'eval'
973 1 0 0 $e->isa('SWF::Builder::ActionScript::SyntaxNode::Literal') || $op[0] eq '&&' || $op[0] eq '||'
1034 0 0 5 $unaryop[1] eq 'UnaryOp' or $unaryop[0] eq '-'
0 0 5 $unaryop[1] eq 'UnaryOp' or $unaryop[0] eq '-' or $unaryop[0] eq '+'
1066 0 0 5 $postop[0] eq '++' or $postop[0] eq '--'
1100 0 0 0 @members == 0 or ref($members[-1]) =~ /:MethodCall$/
1193 2 0 3 /^Identifier$/ or /^Reserved$/
1265 4 0 1 @tree != 2 or not $$self{'stat'}{'Optimize'} & 4
1345 0 0 0 $self->function_declaration || $self->statement
1447 0 0 2 $token[1] eq '}' or $token[2] >= 1
0 2 0 $token[1] eq '}' or $token[2] >= 1 or $token[1] eq ''
1612 0 0 0 $2 or $3
1613 0 0 0 $2 || $3
1672 0 0 0 not $$code[$q] =~ /^:/ or $q >= @$code
2023 0 0 0 $t_self ne $t_term or $t_self eq 'NaN'
0 0 0 $t_self ne $t_term or $t_self eq 'NaN' or $t_term eq 'NaN'
2127 0 0 0 $num1->isa('SWF::Builder::ActionScript::SyntaxNode::NaN') or $num2->isa('SWF::Builder::ActionScript::SyntaxNode::NaN')
2301 0 0 0 $term->isa('SWF::Builder::ActionScript::SyntaxNode::NaN') or $term->isa('SWF::Builder::ActionScript::SyntaxNode::Infinity')
2347 0 0 0 $value =~ /^0[0-7]+$/ or $value =~ /^0x[0-9a-f]$/i
0 0 0 $value =~ /^(?=\d|\.\d)\d*(\.\d*)?([Ee]([+-]?\d+))?$/ || $value =~ /^[-+]?Infinity$/
2430 0 0 0 $term->isa('SWF::Builder::ActionScript::SyntaxNode::UNDEFLiteral') or $term->isa('SWF::Builder::ActionScript::SyntaxNode::NULLLiteral')
2457 0 0 0 $term->isa('SWF::Builder::ActionScript::SyntaxNode::UNDEFLiteral') or $term->isa('SWF::Builder::ActionScript::SyntaxNode::NULLLiteral')
2534 0 0 0 $context eq 'lvalue' or $context eq 'lcvalue'
2537 1 0 1 $context eq 'value' or not $context
2556 0 0 0 $context eq 'value' or not $context
2638 1 0 0 $op eq '=' || !$opt
2996 0 0 0 $context || $$node[0]
3162 0 0 0 $context eq 'value' or not $context
3248 0 0 0 @{$$args{'node'};} > 3 or @{$$args{'node'};} <= 0
3251 0 0 0 $ext || defined $method
0 0 0 !defined($target) || $target->isa('SWF::Builder::ActionScript::SyntaxNode::Literal')
3258 0 0 0 $method eq 'get' or $method eq 'post'
3285 0 0 0 @{$$args{'node'};} > 2 or @{$$args{'node'};} <= 0
3305 0 0 0 @{$$args{'node'};} > 2 or @{$$args{'node'};} <= 0
3444 0 0 0 $bbox eq 'bframe' or $bbox eq 'bmax'
0 0 0 $bbox eq 'bframe' or $bbox eq 'bmax' or $bbox eq 'bmovie'
3487 0 0 0 $n == 1 or $n == 2
0 0 0 $n == 1 or $n == 2 or $n == 6