Branch Coverage

blib/lib/Hydrogen/String.pm
Criterion Covered Total %
branch 93 508 18.3


line true false branch
86 0 4 unless @_ == 2
92 0 4 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
95 4 0 if (defined $_[0])
96 0 4 unless ref \$_[0] eq "SCALAR"
105 0 4 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
108 4 0 if (defined $_[1])
109 0 4 unless ref \$_[1] eq "SCALAR"
123 0 4 unless do { if (defined $shv_final_unchecked) { ref \(my $val = $shv_final_unchecked) eq "SCALAR" unless ref \$shv_final_unchecked eq "SCALAR"; } }
126 4 0 if (defined $shv_final_unchecked)
127 0 4 unless ref \$shv_final_unchecked eq "SCALAR"
151 0 0 unless @_ == 1
168 0 0 unless @_ == 1
185 0 1 unless @_ == 1
207 0 0 unless @_ == 2
213 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
216 0 0 if (defined $_[0])
217 0 0 unless ref \$_[0] eq "SCALAR"
226 0 0 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
229 0 0 if (defined $_[1])
230 0 0 unless ref \$_[1] eq "SCALAR"
258 0 0 unless @_ == 2
264 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
267 0 0 if (defined $_[0])
268 0 0 unless ref \$_[0] eq "SCALAR"
277 0 0 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
280 0 0 if (defined $_[1])
281 0 0 unless ref \$_[1] eq "SCALAR"
309 0 0 unless @_ == 2
315 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
318 0 0 if (defined $_[0])
319 0 0 unless ref \$_[0] eq "SCALAR"
328 0 0 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
331 0 0 if (defined $_[1])
332 0 0 unless ref \$_[1] eq "SCALAR"
360 0 0 unless @_ == 2
366 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
369 0 0 if (defined $_[0])
370 0 0 unless ref \$_[0] eq "SCALAR"
379 0 0 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
382 0 0 if (defined $_[1])
383 0 0 unless ref \$_[1] eq "SCALAR"
411 0 0 unless @_ == 2
417 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
420 0 0 if (defined $_[0])
421 0 0 unless ref \$_[0] eq "SCALAR"
430 0 0 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
433 0 0 if (defined $_[1])
434 0 0 unless ref \$_[1] eq "SCALAR"
462 0 0 unless @_ == 2
468 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
471 0 0 if (defined $_[0])
472 0 0 unless ref \$_[0] eq "SCALAR"
481 0 0 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
484 0 0 if (defined $_[1])
485 0 0 unless ref \$_[1] eq "SCALAR"
513 0 0 unless @_ == 2
519 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
522 0 0 if (defined $_[0])
523 0 0 unless ref \$_[0] eq "SCALAR"
532 0 0 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
535 0 0 if (defined $_[1])
536 0 0 unless ref \$_[1] eq "SCALAR"
564 0 0 unless @_ == 2
570 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
573 0 0 if (defined $_[0])
574 0 0 unless ref \$_[0] eq "SCALAR"
583 0 0 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
586 0 0 if (defined $_[1])
587 0 0 unless ref \$_[1] eq "SCALAR"
610 0 0 unless @_ == 1
631 0 0 unless @_ == 2
637 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
640 0 0 if (defined $_[0])
641 0 0 unless ref \$_[0] eq "SCALAR"
650 0 0 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
653 0 0 if (defined $_[1])
654 0 0 unless ref \$_[1] eq "SCALAR"
682 0 0 unless @_ == 2
688 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
691 0 0 if (defined $_[0])
692 0 0 unless ref \$_[0] eq "SCALAR"
701 0 0 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
704 0 0 if (defined $_[1])
705 0 0 unless ref \$_[1] eq "SCALAR"
728 0 1 unless @_ == 1
749 0 0 unless @_ == 2
755 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
758 0 0 if (defined $_[0])
759 0 0 unless ref \$_[0] eq "SCALAR"
768 0 0 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
771 0 0 if (defined $_[1])
772 0 0 unless ref \$_[1] eq "SCALAR"
800 0 0 unless @_ == 2
806 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
809 0 0 if (defined $_[0])
810 0 0 unless ref \$_[0] eq "SCALAR"
819 0 0 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
822 0 0 if (defined $_[1])
823 0 0 unless ref \$_[1] eq "SCALAR"
846 0 0 unless @_ == 1
863 0 0 unless @_ == 1
884 0 0 unless @_ == 2
890 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
893 0 0 if (defined $_[0])
894 0 0 unless ref \$_[0] eq "SCALAR"
903 0 0 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
906 0 0 if (defined $_[1])
907 0 0 unless ref \$_[1] eq "SCALAR"
935 0 0 unless @_ == 2
941 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
944 0 0 if (defined $_[0])
945 0 0 unless ref \$_[0] eq "SCALAR"
954 0 0 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
957 0 0 if (defined $_[1])
958 0 0 unless ref \$_[1] eq "SCALAR"
981 0 1 unless @_ == 1
1002 0 0 unless @_ == 2
1008 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
1011 0 0 if (defined $_[0])
1012 0 0 unless ref \$_[0] eq "SCALAR"
1021 0 0 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
1024 0 0 if (defined $_[1])
1025 0 0 unless ref \$_[1] eq "SCALAR"
1053 0 0 unless @_ == 2
1059 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
1062 0 0 if (defined $_[0])
1063 0 0 unless ref \$_[0] eq "SCALAR"
1072 0 0 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
1075 0 0 if (defined $_[1])
1076 0 0 unless ref \$_[1] eq "SCALAR"
1104 0 1 unless @_ == 2
1110 0 1 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
1113 1 0 if (defined $_[0])
1114 0 1 unless ref \$_[0] eq "SCALAR"
1123 0 1 unless do { unless (do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }) { &Scalar::Util::blessed($_[1]) and $_[1]->isa("Regexp") unless ref $_[1] and not !&re::is_regexp($_[1]); } }
1130 1 0 if (defined $_[1])
1131 0 1 unless ref \$_[1] eq "SCALAR"
1136 0 1 unless (do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } })
1141 0 0 unless ref $_[1] and not !&re::is_regexp($_[1])
1172 0 1 unless @_ == 2
1178 0 1 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
1181 1 0 if (defined $_[0])
1182 0 1 unless ref \$_[0] eq "SCALAR"
1191 0 1 unless do { unless (do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }) { &Scalar::Util::blessed($_[1]) and $_[1]->isa("Regexp") unless ref $_[1] and not !&re::is_regexp($_[1]); } }
1198 1 0 if (defined $_[1])
1199 0 1 unless ref \$_[1] eq "SCALAR"
1204 0 1 unless (do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } })
1209 0 0 unless ref $_[1] and not !&re::is_regexp($_[1])
1240 0 0 unless @_ == 2
1246 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
1249 0 0 if (defined $_[0])
1250 0 0 unless ref \$_[0] eq "SCALAR"
1259 0 0 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
1262 0 0 if (defined $_[1])
1263 0 0 unless ref \$_[1] eq "SCALAR"
1291 0 0 unless @_ == 2
1297 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
1300 0 0 if (defined $_[0])
1301 0 0 unless ref \$_[0] eq "SCALAR"
1310 0 0 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
1313 0 0 if (defined $_[1])
1314 0 0 unless ref \$_[1] eq "SCALAR"
1342 0 1 unless @_ == 2
1348 0 1 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
1351 1 0 if (defined $_[0])
1352 0 1 unless ref \$_[0] eq "SCALAR"
1361 0 1 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
1364 1 0 if (defined $_[1])
1365 0 1 unless ref \$_[1] eq "SCALAR"
1379 0 1 unless do { if (defined $shv_final_unchecked) { ref \(my $val = $shv_final_unchecked) eq "SCALAR" unless ref \$shv_final_unchecked eq "SCALAR"; } }
1382 1 0 if (defined $shv_final_unchecked)
1383 0 1 unless ref \$shv_final_unchecked eq "SCALAR"
1413 0 2 unless @_ == 3
1419 0 2 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
1422 2 0 if (defined $_[0])
1423 0 2 unless ref \$_[0] eq "SCALAR"
1432 0 2 unless do { unless (do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }) { &Scalar::Util::blessed($_[1]) and $_[1]->isa("Regexp") unless ref $_[1] and not !&re::is_regexp($_[1]); } }
1439 2 0 if (defined $_[1])
1440 1 1 unless ref \$_[1] eq "SCALAR"
1445 1 1 unless (do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } })
1450 0 1 unless ref $_[1] and not !&re::is_regexp($_[1])
1462 0 2 unless do { ref $_[2] eq "CODE" unless do { if (defined $_[2]) { ref \(my $val = $_[2]) eq "SCALAR" unless ref \$_[2] eq "SCALAR"; } } }
1466 1 1 unless do { if (defined $_[2]) { ref \(my $val = $_[2]) eq "SCALAR" unless ref \$_[2] eq "SCALAR"; } }
1469 2 0 if (defined $_[2])
1470 1 1 unless ref \$_[2] eq "SCALAR"
1484 1 1 if (ref $_[2] eq 'CODE') { }
1493 0 2 unless do { if (defined $shv_final_unchecked) { ref \(my $val = $shv_final_unchecked) eq "SCALAR" unless ref \$shv_final_unchecked eq "SCALAR"; } }
1496 2 0 if (defined $shv_final_unchecked)
1497 0 2 unless ref \$shv_final_unchecked eq "SCALAR"
1527 0 2 unless @_ == 3
1533 0 2 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
1536 2 0 if (defined $_[0])
1537 0 2 unless ref \$_[0] eq "SCALAR"
1547 0 2 unless do { unless (do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }) { &Scalar::Util::blessed($_[1]) and $_[1]->isa("Regexp") unless ref $_[1] and not !&re::is_regexp($_[1]); } }
1554 2 0 if (defined $_[1])
1555 1 1 unless ref \$_[1] eq "SCALAR"
1560 1 1 unless (do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } })
1565 0 1 unless ref $_[1] and not !&re::is_regexp($_[1])
1578 0 2 unless do { ref $_[2] eq "CODE" unless do { if (defined $_[2]) { ref \(my $val = $_[2]) eq "SCALAR" unless ref \$_[2] eq "SCALAR"; } } }
1582 1 1 unless do { if (defined $_[2]) { ref \(my $val = $_[2]) eq "SCALAR" unless ref \$_[2] eq "SCALAR"; } }
1585 2 0 if (defined $_[2])
1586 1 1 unless ref \$_[2] eq "SCALAR"
1601 1 1 if (ref $_[2] eq 'CODE') { }
1610 0 2 unless do { if (defined $shv_final_unchecked) { ref \(my $val = $shv_final_unchecked) eq "SCALAR" unless ref \$shv_final_unchecked eq "SCALAR"; } }
1613 2 0 if (defined $shv_final_unchecked)
1614 0 2 unless ref \$shv_final_unchecked eq "SCALAR"
1639 0 0 unless @_ == 1
1646 0 0 unless do { if (defined $shv_final_unchecked) { ref \(my $val = $shv_final_unchecked) eq "SCALAR" unless ref \$shv_final_unchecked eq "SCALAR"; } }
1649 0 0 if (defined $shv_final_unchecked)
1650 0 0 unless ref \$shv_final_unchecked eq "SCALAR"
1679 0 1 unless @_ == 2
1685 0 1 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
1688 1 0 if (defined $_[0])
1689 0 1 unless ref \$_[0] eq "SCALAR"
1698 0 1 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
1701 1 0 if (defined $_[1])
1702 0 1 unless ref \$_[1] eq "SCALAR"
1716 0 1 unless do { if (defined $shv_final_unchecked) { ref \(my $val = $shv_final_unchecked) eq "SCALAR" unless ref \$shv_final_unchecked eq "SCALAR"; } }
1719 1 0 if (defined $shv_final_unchecked)
1720 0 1 unless ref \$shv_final_unchecked eq "SCALAR"
1749 0 0 unless @_ == 2
1755 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
1758 0 0 if (defined $_[0])
1759 0 0 unless ref \$_[0] eq "SCALAR"
1768 0 0 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
1771 0 0 if (defined $_[1])
1772 0 0 unless ref \$_[1] eq "SCALAR"
1800 0 0 unless @_ == 2
1806 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
1809 0 0 if (defined $_[0])
1810 0 0 unless ref \$_[0] eq "SCALAR"
1820 0 0 unless do { if (defined $_[1]) { ref \(my $val = $_[1]) eq "SCALAR" unless ref \$_[1] eq "SCALAR"; } }
1823 0 0 if (defined $_[1])
1824 0 0 unless ref \$_[1] eq "SCALAR"
1856 0 0 unless @_ >= 2 and @_ <= 4
1862 0 0 unless do { if (defined $_[0]) { ref \(my $val = $_[0]) eq "SCALAR" unless ref \$_[0] eq "SCALAR"; } }
1865 0 0 if (defined $_[0])
1866 0 0 unless ref \$_[0] eq "SCALAR"
1876 0 0 unless do { my $tmp = $_[1]; $tmp =~ /\A-?[0-9]+\z/ if defined $tmp and not ref $tmp }
1878 0 0 if defined $tmp and not ref $tmp
1886 0 0 unless $#_ >= 2
1889 0 0 unless do { my $tmp = $_[2]; $tmp =~ /\A-?[0-9]+\z/ if defined $tmp and not ref $tmp }
1891 0 0 if defined $tmp and not ref $tmp
1899 0 0 unless $#_ >= 3
1901 0 0 unless do { if (defined $_[3]) { ref \(my $val = $_[3]) eq "SCALAR" unless ref \$_[3] eq "SCALAR"; } }
1904 0 0 if (defined $_[3])
1905 0 0 unless ref \$_[3] eq "SCALAR"
1916 0 0 if (@_ - 1 == 1) { }
0 0 elsif (@_ - 1 == 2) { }
0 0 elsif (@_ - 1 == 3) { }
1925 0 0 unless do { if (defined $shv_final_unchecked) { ref \(my $val = $shv_final_unchecked) eq "SCALAR" unless ref \$shv_final_unchecked eq "SCALAR"; } }
1928 0 0 if (defined $shv_final_unchecked)
1929 0 0 unless ref \$shv_final_unchecked eq "SCALAR"
1957 0 0 unless @_ == 1