Branch Coverage

blib/lib/DBIx/MyParsePP/Lexer.pm
Criterion Covered Total %
branch 138 286 48.2


line true false branch
104 84 0 if (exists $args{$_[$i * 2]}) { }
117 14 0 unless defined $lexer->[5]
118 14 0 unless defined $lexer->[6]
119 13 1 unless defined $lexer->[3]
121 12 2 unless defined $lexer->[2]
122 14 0 unless defined $lexer->[1]
130 0 14 if ($@)
178 12 769 if ($res[0] eq '0' and $res[1] eq '0') { }
208 576 258 if ($state eq 'MY_LEX_OPERATOR_OR_IDENT' or $state eq 'MY_LEX_START')
213 105 836 if $c == 10
219 0 834 if ($state eq 'MY_LEX_ESCAPE')
220 0 0 if $lexer->yyGet == 78
223 112 722 if ($state eq 'MY_LEX_ESCAPE' or $state eq 'MY_LEX_CHAR' or $state eq 'MY_LEX_SKIP') { }
4 718 elsif ($state eq 'MY_LEX_IDENT_OR_NCHAR') { }
0 718 elsif ($state eq 'MY_LEX_IDENT_OR_HEX') { }
7 711 elsif ($state eq 'MY_LEX_IDENT_OR_BIN') { }
228 0 0 if ($c == 45 and $lexer->yyPeek == 45 and $lexer->my_isspace($lexer->yyPeek2) || $lexer->my_iscntrl($lexer->yyPeek2))
243 82 30 if $c != 41
245 40 72 if ($c == 44) { }
0 144 elsif ($c == 63 and not $$ident_map[$lexer->yyPeek]) { }
252 4 0 if ($lexer->yyPeek != 39)
259 0 0 unless (defined($lex_str = $lexer->get_text))
265 0 0 if ($lexer->yyPeek == 39)
270 0 7 if ($lexer->yyPeek == 39)
276 329 389 if ($state eq 'MY_LEX_IDENT_OR_HEX' or $state eq 'MY_LEX_IDENT_OR_BIN' or $state eq 'MY_LEX_IDENT') { }
107 282 elsif ($state eq 'MY_LEX_IDENT_SEP') { }
27 255 elsif ($state eq 'MY_LEX_NUMBER_IDENT') { }
286 0 329 $result_state & 128 ? :
291 0 329 if ($lexer->[3] & 8)
295 103 226 if ($start == $lexer->[7] and $c == 46 and $$ident_map[$lexer->yyPeek]) { }
303 157 69 if (@token = $lexer->find_keyword($length, $c == 40))
311 0 172 if (substr($lex_str, 0, 1) eq '_' and exists $$DBIx::MyParsePP::Charsets::charsets{substr $lex_str, 1})
323 2 105 unless ($$ident_map[$lexer->yyPeek])
329 27 0 unless ($ident_map->[$c])
333 0 0 if ($c == 101 or $c == 69) { }
0 0 elsif ($c == 120 and $lexer->[7] - $lexer->[8] == 2 and substr($string, $lexer->[8], 1) eq '0') { }
0 0 elsif ($c == 98 and $lexer->[7] - $lexer->[8] == 2 and substr($string, $lexer->[8], 1) eq '0') { }
334 0 0 if ($lexer->my_isdigit($lexer->yyPeek) or $c = $lexer->yyGet == 43 or $c == 45)
339 0 0 if ($lexer->my_isdigit($lexer->yyPeek))
353 0 0 if ($lexer->[7] - $lexer->[8] >= 4 and not $ident_map->[$c])
365 0 0 if ($lexer->[7] - $lexer->[8] >= 4 and not $ident_map->[$c])
374 105 150 if ($state eq 'MY_LEX_IDENT_START') { }
3 147 elsif ($state eq 'MY_LEX_USER_VARIABLE_DELIMITER') { }
27 120 elsif ($state eq 'MY_LEX_INT_OR_REAL') { }
378 0 105 $result_state & 128 ? :
380 2 103 if ($c == 46 and $$ident_map[$lexer->yyPeek])
392 20 0 if ($var_length == 1)
393 0 20 if $c == 92
394 3 17 if ($c == $quote_char)
395 3 0 if $lexer->yyPeek != $quote_char
406 0 3 if ($double_quotes) { }
412 3 0 if $c == $quote_char
416 27 0 if ($c != 46)
422 0 120 if ($state eq 'MY_LEX_INT_OR_REAL' or $state eq 'MY_LEX_REAL') { }
0 120 elsif ($state eq 'MY_LEX_HEX_NUMBER') { }
0 120 elsif ($state eq 'MY_LEX_BIN_NUMBER') { }
50 70 elsif ($state eq 'MY_LEX_CMP_OP') { }
0 70 elsif ($state eq 'MY_LEX_LONG_CMP_OP') { }
2 68 elsif ($state eq 'MY_LEX_BOOL') { }
4 64 elsif ($state eq 'MY_LEX_STRING_OR_DELIMITER') { }
427 0 0 if ($c == 101 or $c == 69)
432 0 0 if ($c == 43 or $c == 45)
439 0 0 unless ($lexer->my_isdigit($c))
456 0 0 if (not $length & 1 or $c != 39)
467 0 0 if ($c != 39)
475 1 49 if ($$state_map[$lexer->yyPeek] eq 'MY_LEX_CMP_OP' or $$state_map[$lexer->yyPeek] eq 'MY_LEX_LONG_CMP_OP')
481 50 0 if (@token = $lexer->find_keyword($lexer->[7] - $lexer->[8], 0))
488 0 0 if ($$state_map[$lexer->yyPeek] eq 'MY_LEX_CMP_OP' or $$state_map[$lexer->yyPeek] eq 'MY_LEX_LONG_CMP_OP')
493 0 0 if ($$state_map[$lexer->yyPeek] eq 'MY_LEX_CMP_OP')
497 0 0 if (@token = $lexer->find_keyword($lexer->[7] - $lexer->[8], 0))
504 0 2 if ($c != $lexer->yyPeek)
513 0 4 if ($lexer->[3] & 4)
519 19 49 if ($state eq 'MY_LEX_STRING_OR_DELIMITER' or $state eq 'MY_LEX_STRING') { }
0 49 elsif ($state eq 'MY_LEX_COMMENT') { }
17 32 elsif ($state eq 'MY_LEX_LONG_COMMENT') { }
3 29 elsif ($state eq 'MY_LEX_END_LONG_COMMENT') { }
0 29 elsif ($state eq 'MY_LEX_SET_VAR') { }
1 28 elsif ($state eq 'MY_LEX_SEMICOLON') { }
524 0 19 unless (defined($lex_str = $lexer->get_text))
536 1 16 if ($lexer->yyPeek != 42)
542 2 14 if ($lexer->yyPeek == 33)
546 2 0 if ($lexer->my_isdigit($lexer->yyPeek))
551 1 1 if ($version <= $lexer->[2])
564 0 447 if $c == 10
567 15 0 if $lexer->[7] != length($string) - 1
572 1 2 if ($lexer->[12] and $lexer->yyPeek == 47) { }
581 0 0 if ($lexer->yyPeek != 61)
588 1 0 if ($lexer->yyPeek)
589 1 0 if ($lexer->[5] & 65536 and not $lexer->[6])
604 13 15 if ($state eq 'MY_LEX_SEMICOLON' or $state eq 'MY_LEX_EOL') { }
12 3 elsif ($state eq 'MY_LEX_END') { }
2 1 elsif ($state eq 'MY_LEX_REAL_OR_POINT') { }
1 0 elsif ($state eq 'MY_LEX_USER_END') { }
0 0 elsif ($state eq 'MY_LEX_HOSTNAME') { }
0 0 elsif ($state eq 'MY_LEX_SYSTEM_VAR') { }
0 0 elsif ($state eq 'MY_LEX_IDENT_OR_KEYWORD') { }
608 13 0 if ($lexer->[7] >= length($string) - 1)
618 0 2 if ($lexer->my_isdigit($lexer->yyPeek)) { }
626 0 1 if ($$state_map[$lexer->yyPeek] eq 'MY_LEX_STRING' or $$state_map[$lexer->yyPeek] eq 'MY_LEX_STRING_OR_DELIMITER') { }
0 1 elsif ($$state_map[$lexer->yyPeek] eq 'MY_LEX_USER_END') { }
1 0 elsif ($$state_map[$lexer->yyPeek] eq 'MY_LEX_USER_VARIABLE_DELIMITER') { }
647 0 0 $$state_map[$lexer->yyPeek] eq 'MY_LEX_USER_VARIABLE_DELIMITER' ? :
651 0 0 $result_state & 128 ? :
653 0 0 if $c == 46
656 0 0 if $length == 0
657 0 0 if (@token = $lexer->find_keyword($length, 0))
671 6 8 if exists $state_maps{$lexer->[1]}
677 416 1632 if ($lexer->my_isalpha($i)) { }
80 1552 elsif ($lexer->my_isdigit($i)) { }
48 1504 elsif ($lexer->my_isspace($i)) { }
741 0 90 if ($c == 92 and not $lexer->[3] & 1048576) { }
19 71 elsif ($c == $sep) { }
746 0 0 if $lexer->[7] == length $lexer->[0]
749 0 19 if ($c == $lexer->yyGet) { }
763 19 0 if (not $found_escape) { }
765 19 0 if ($yytoklen > 0) { }
773 0 0 if (not $lexer->[3] & 1048576 and substr($string, $str, 1) eq '\\' and $str + 1 != $end) { }
0 0 elsif (substr($string, $str, 1) eq $sep) { }
779 0 0 if ($prev_str eq 'n') { }
0 0 elsif ($prev_str eq 't') { }
0 0 elsif ($prev_str eq 'r') { }
0 0 elsif ($prev_str eq 'b') { }
0 0 elsif ($prev_str eq '0') { }
0 0 elsif ($prev_str eq 'Z') { }
0 0 elsif ($prev_str eq '_' or $prev_str eq '%') { }
839 27 0 if (length $token < 10)
845 0 0 if (substr($token, 0, 1) eq '+') { }
0 0 elsif (substr($token, 0, 1) eq '-') { }
859 0 0 if (length $token < 10)
866 0 0 if ($neg) { }
867 0 0 if (length $token == 10) { }
0 0 elsif (length $token < 19) { }
0 0 elsif (length $token > 19) { }
881 0 0 if (length $token == 19) { }
0 0 elsif (length $token < 19) { }
0 0 elsif (length $token > 19) { }
888 0 0 if (length $token > 20)
901 0 0 $token > $cmp ? :
909 10 268 if ($function) { }
911 3 7 unless defined $symbol
916 69 209 unless defined $symbol
918 0 209 if ($symbol eq 'NOT_SYM' and $lexer->[3] & 536870912)
925 1 208 if ($symbol eq 'OR_OR_SYM' and $lexer->[3] & 2)