Branch Coverage

blib/lib/Lingua/AlignmentSlice.pm
Criterion Covered Total %
branch 0 160 0.0


line true false branch
69 0 0 unless (defined $al)
87 0 0 if ($$this{$side . 'Indices'}{'0'})
94 0 0 unless ($$this{$reverseSide . 'Indices'}{$i - $$this{'zero' . $ReverseSide}})
111 0 0 if ($j > 0)
117 0 0 if ($i > 0) { }
169 0 0 if (defined $j)
170 0 0 if (@{$$alSlice{$source . 'Al'}[$j];} > 1)
176 0 0 if (@{$$alSlice{$target . 'Al'}[$i];} == 1 and $$alSlice{$target . 'Al'}[$i][0] == $j) { }
0 0 elsif (@{$$alSlice{$target . 'Al'}[$i];} >= 1) { }
184 0 0 if (not $failed and %candidate > 0)
189 0 0 if (not $candidate{$i}) { }
221 0 0 if (@toModify == 0)
225 0 0 if (@{$$alSlice{$source . 'Al'};} == 2 and @{$$alSlice{$source . 'Al'}[0];} == 0 and @{$$alSlice{$target . 'Words'};} - scalar(keys %{$$alSlice{$target . 'Indices'};}) < 4)
228 0 0 if (@{$$alSlice{$source . 'Al'}[$j];} == scalar keys %{$$alSlice{$target . 'Indices'};})
235 0 0 if (@{$$alSlice{$target . 'Al'}[$i];} == 1 and $$alSlice{$target . 'Al'}[$i][0] == $j) { }
246 0 0 if (@candidate > 0)
268 0 0 if ($sourceSize > 0 and $targetSize > 0 and $sourceSize > 1 || $targetSize > 1 and not $alSlice->sparse('source') and not $alSlice->sparse('target'))
284 0 0 if ($$globals{'onlyGroups'} == 0)
291 0 0 if ($numWords < 3) { }
0 0 elsif ($numWords < 5) { }
316 0 0 if ($sourceSize > 0 and $targetSize > 0 and $sourceSize > 1 || $targetSize > 1)
355 0 0 if ($sourceSize > 1 and $targetSize > 1 and not $alSlice->sparse('source') and not $alSlice->sparse('target'))
361 0 0 if (defined $$clone{'sourceAl'}[$j])
367 0 0 if ($verbose > 1)
369 0 0 if ($verbose > 2)
391 0 0 unless ($lastChance or $modifications)
393 0 0 if ($$globals{'onlyGroups'} == 1)
402 0 0 if ($nscan == 0 or $modifications)
408 0 0 if ($verbose > 2)
414 0 0 if ($toProcess{$side . 'Words'}[$idx] =~ /[\(\)\?\277!\241\.,]/ or not $$alSlice{$side . 'Indices'}{$toProcess{$side . 'WordPos'}[$idx]}) { }
416 0 0 unless ($idx == 0 or $idx == @{$toProcess{$side . 'Words'};} - 1 or $pushed == 0)
427 0 0 if (scalar keys %{$toProcess{$side . 'Indices'};} < 4) { }
0 0 elsif (scalar keys %{$toProcess{$side . 'Indices'};} < 5) { }
443 0 0 if (@words > 0 and @words < $minK and $j == 0 || $j == @{$allWords[$interPunctuationIdx];} - $k)
459 0 0 unless ($candidate =~ /^(\[\^ \]\+ ?)+$/)
464 0 0 if ($verbose > 2)
467 0 0 if ($side eq 'source') { }
468 0 0 if (not $lastChance) { }
474 0 0 if (not $lastChance) { }
481 0 0 if ($verbose > 2)
483 0 0 if (@grepMatch > 0)
504 0 0 if ($verbose > 2)
508 0 0 if (not $lastChance) { }
515 0 0 if (@grepMatch > 0)
527 0 0 if ($verbose > 2)
532 0 0 if (@matches == 0) { }
534 0 0 if ($lastChance)
535 0 0 if ($modified) { }
540 0 0 if (@matches == 1) { }
543 0 0 if ($lastChance) { }
550 0 0 if ($verbose > 0)
556 0 0 if ($toProcess{'sourceWordPos'}[$j] == $$refToSourceCand[0]{'pos'})
562 0 0 if ($toProcess{'targetWordPos'}[$i] == $$refToTargetCand[0]{'pos'})
589 0 0 if ($modifications > 0)
625 0 0 if ($verbose > 1)
633 0 0 if ($$match[0] == $maxMatch)
637 0 0 if (@bestCandidates > 1)
642 0 0 if ($length > $maxLength{'length'})
678 0 0 if ($$match[0] == $sortedMatchNums[$idx])
687 0 0 if ((printGroup($$match[1]) . ' | ' . printGroup($$match[2])) =~ /$regExp/)
693 0 0 if ($thisOneWithCross) { }
699 0 0 if (@candsWithCrossLink > 0) { }
713 0 0 if (@candsWithCrossLink > 0) { }
715 0 0 if ($idx > 0 and @candsWithoutCrossLink > 0)
745 0 0 if ($clusterPositions{$k}{$$word{'pos'}})
751 0 0 if ($isInCluster{'1'} or $isInCluster{'2'})
769 0 0 if ($clusterPositions{$k}{$$word{'pos'}})
772 0 0 if ($cluster{$k}[$l]{'pos'} > $$word{'pos'})
799 0 0 if ($extendGroup == 1)
802 0 0 if (defined $$alSlice{'sourceAl'}[$j] and @{$$alSlice{'sourceAl'}[$j];} > 0 and $j < $first_j || $j > $last_j)
804 0 0 if ($alSlice->isCrossLink($j, $i))
805 0 0 if ($j < $first_j)
806 0 0 if ($j > $last_j)
812 0 0 if (defined $$alSlice{'targetAl'}[$i] and @{$$alSlice{'targetAl'}[$i];} > 0 and $i < $first_i || $i > $last_i)
814 0 0 if ($alSlice->isCrossLink($j, $i))
815 0 0 if ($i < $first_i)
816 0 0 if ($i > $last_i)
825 0 0 if ($$alSlice{'sourceIndices'}{$j} and $$alSlice{'targetIndices'}{$i})
826 0 0 unless ($alSlice->isIn('sourceAl', $j, $i))
830 0 0 unless ($alSlice->isIn('targetAl', $i, $j))