line |
true |
false |
branch |
23
|
30 |
71 |
if &$f()
|
30
|
1 |
0 |
if (eval {
|
|
0 |
0 |
elsif (eval {
|
|
0 |
0 |
elsif (eval {
|
41
|
0 |
1 |
if ($@) { }
|
47
|
2 |
0 |
if ($cleanser) { }
|
61
|
12 |
0 |
if ($header_row) { }
|
73
|
0 |
12 |
if ($ENV{'FORMAT_PRETTY_TABLE_COLUMN_ORDERS'}) { }
|
|
0 |
12 |
elsif (my $rfos = $resmeta->{'cmdline.format_options'} // $resmeta->{'format_options'}) { }
|
78
|
0 |
0 |
if ($rfo)
|
82
|
0 |
12 |
if ($tcos)
|
87
|
0 |
0 |
unless &first(sub {
|
94
|
1 |
11 |
if ($resmeta->{'table.field_orders'})
|
104
|
11 |
1 |
if ($column_orders)
|
130
|
2 |
10 |
unless my $tff = $resmeta->{'table.fields'}
|
138
|
0 |
12 |
unless $header_row and @$data
|
139
|
2 |
10 |
unless my $tff = $resmeta->{'table.fields'}
|
144
|
10 |
30 |
unless $field_idx >= 0
|
145
|
2 |
28 |
if ($tfl and defined $tfl->[$field_idx]) { }
|
|
3 |
50 |
elsif ($tfu and defined $tfu->[$field_idx]) { }
|
159
|
9 |
0 |
unless $tffmt or $tffmt_code or $tffmt_default
|
164
|
4 |
8 |
$tffmt_code ? :
|
165
|
9 |
3 |
if $field_idx >= 0
|
167
|
6 |
6 |
if (ref $fmt eq 'ARRAY') { }
|
179
|
3 |
3 |
if $i == 0 and $header_row
|
182
|
0 |
12 |
unless defined $row->[$j]
|
185
|
2 |
10 |
unless $fmt_name
|
187
|
4 |
6 |
if ($fmt_name eq 'iso8601_datetime' or $fmt_name eq 'iso8601_date') { }
|
|
0 |
6 |
elsif ($fmt_name eq 'boolstr') { }
|
|
0 |
6 |
elsif ($fmt_name eq 'filesize') { }
|
|
0 |
6 |
elsif ($fmt_name eq 'sci2dec') { }
|
|
0 |
6 |
elsif ($fmt_name eq 'percent') { }
|
|
6 |
0 |
elsif ($fmt_name eq 'number') { }
|
188
|
4 |
0 |
if ($row->[$j] =~ /\A[0-9]+(\.[0-9]*)?\z/)
|
189
|
0 |
4 |
$1 ? :
|
191
|
1 |
3 |
if ($fmt_name eq 'iso8601_datetime') { }
|
192
|
0 |
1 |
$frac ? :
|
202
|
0 |
0 |
$row->[$j] ? :
|
207
|
0 |
0 |
if ($row->[$j] =~ /\A(?:[+-]?)(?:\d+\.|\d*\.(\d+))[eE]([+-]?\d+)\z/)
|
208
|
0 |
0 |
if $n < 0
|
228
|
12 |
0 |
if ($format eq 'text-pretty') { }
|
|
0 |
0 |
elsif ($format eq 'csv') { }
|
|
0 |
0 |
elsif ($format eq 'html') { }
|
238
|
9 |
0 |
unless $tfa or $tfa_code or $tfa_default
|
239
|
0 |
3 |
unless @$data
|
243
|
3 |
9 |
$tfa_code ? :
|
244
|
8 |
4 |
if $field_idx >= 0
|
246
|
1 |
11 |
unless $align
|
251
|
3 |
8 |
if ($align eq 'number')
|
255
|
15 |
0 |
if (@$row > $colidx) { }
|
257
|
3 |
12 |
if ($header_row and $i == 0) { }
|
|
8 |
4 |
elsif ($cell =~ /\A([+-]?\d+)(\.?)(\d*)\z/) { }
|
|
4 |
0 |
elsif ($cell =~ /\A([+-]?\d+\.?\d*)([eE])([+-]?\d+)\z/) { }
|
287
|
3 |
0 |
if ($header_row)
|
289
|
1 |
2 |
if ($maxw_d == 0 and $maxw_ad == 0)
|
296
|
55 |
0 |
@$_ > $colidx ? :
|
304
|
0 |
275 |
unless @$row > $colidx
|
306
|
0 |
275 |
unless defined $cell
|
307
|
75 |
200 |
if ($align eq 'number') { }
|
|
75 |
125 |
elsif ($align eq 'right') { }
|
|
50 |
75 |
elsif ($align eq 'middle' or $align eq 'center') { }
|
309
|
15 |
60 |
if ($header_row and $i == 0) { }
|
|
8 |
52 |
elsif (($bd, $d, $ad) = $cell =~ /\A([+-]?\d+)(\.?)(\d*)\z/) { }
|
|
4 |
48 |
elsif (($bd, $d, $ad) = $cell =~ /\A([+-]?\d+\.?\d*)([eE])([+-]?\d+)\z/) { }
|
326
|
4 |
71 |
if $maxw > $w
|
347
|
0 |
12 |
if $ENV{'INSIDE_EMACS'}
|
348
|
0 |
12 |
if ($backend) { }
|
355
|
12 |
0 |
unless $fres =~ /\R\z/ or not length $fres
|
381
|
0 |
0 |
$resmeta->{'table.html_class'} ? :
|
384
|
0 |
0 |
$i == 0 ? :
|
385
|
0 |
0 |
if $i == 0
|
386
|
0 |
0 |
if $i == 1
|
392
|
0 |
0 |
if ($field_idx >= 0 and $tfa->[$field_idx])
|
394
|
0 |
0 |
if $align eq 'number'
|
395
|
0 |
0 |
if $align eq 'center'
|
397
|
0 |
0 |
$align ? :
|
403
|
0 |
0 |
if $i == 0
|
410
|
0 |
0 |
if $header_row
|
418
|
16 |
2 |
if ($format =~ /\A(text|text-simple|text-pretty|csv|html)\z/)
|
419
|
0 |
0 |
-t STDOUT ? :
|
|
0 |
16 |
$format eq 'text' ? :
|
422
|
1 |
15 |
if (not $res->[0] =~ /^(2|304)/) { }
|
|
0 |
15 |
elsif ($res->[3] and $res->[3]{'x.hint.result_binary'}) { }
|
424
|
0 |
1 |
if (my $prev = $res->[3]{'prev'})
|
434
|
3 |
12 |
if (not ref $data) { }
|
|
0 |
12 |
elsif (ref $data eq 'ARRAY' and not @$data) { }
|
|
0 |
12 |
elsif (Data::Check::Structure::is_aos($data, {'max', $max})) { }
|
|
0 |
12 |
elsif (Data::Check::Structure::is_aoaos($data, {'max', $max})) { }
|
|
1 |
11 |
elsif (Data::Check::Structure::is_hos($data, {'max', $max})) { }
|
|
11 |
0 |
elsif (Data::Check::Structure::is_aohos($data, {'max', $max})) { }
|
436
|
1 |
2 |
unless not length $data or $data =~ /\n\z/
|
445
|
0 |
0 |
if ($res->[3]{'table.fields'})
|
457
|
1 |
10 |
if ($res->[3] and $res->[3]{'table.fields'} and $res->[3]{'table.hide_unknown_fields'}) { }
|
480
|
0 |
2 |
if $is_naked
|
482
|
0 |
2 |
if ($format eq 'perl')
|
484
|
0 |
0 |
if ($use_color and eval {
|
|
0 |
0 |
elsif (eval {
|
502
|
1 |
1 |
unless ($format =~ /\Ajson(-pretty)?\z/)
|
506
|
2 |
0 |
if $cleanse // 1
|
507
|
2 |
0 |
if ($format =~ /json/)
|
508
|
0 |
0 |
if ($tff and _json()->can('sort_by') and eval {
|
514
|
0 |
2 |
if ($format eq 'json') { }
|