line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Text::CSV::Unicode; |
2
|
|
|
|
|
|
|
|
3
|
2
|
|
|
2
|
|
71747
|
use strict; |
|
2
|
|
|
|
|
16
|
|
|
2
|
|
|
|
|
61
|
|
4
|
2
|
|
|
2
|
|
11
|
use warnings; |
|
2
|
|
|
|
|
3
|
|
|
2
|
|
|
|
|
59
|
|
5
|
|
|
|
|
|
|
|
6
|
2
|
|
|
2
|
|
10
|
use base qw(Text::CSV); |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
1579
|
|
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
our $VERSION = '0.400'; |
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
sub new { |
11
|
5
|
|
|
5
|
1
|
5460
|
my ($self, $hash) = @_; |
12
|
5
|
100
|
100
|
|
|
36
|
if ( $hash and $hash -> {binary} ) { |
13
|
2
|
|
|
|
|
408
|
warnings::warnif("deprecated", |
14
|
|
|
|
|
|
|
"binary is deprecated: use Text::CSV"); |
15
|
2
|
|
|
|
|
49
|
return Text::CSV->new( $hash ); |
16
|
|
|
|
|
|
|
} |
17
|
3
|
100
|
|
|
|
8
|
return $self->SUPER::new( { binary => 1, %{ $hash || {} } } ); |
|
3
|
|
|
|
|
30
|
|
18
|
|
|
|
|
|
|
} |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
sub combine { |
21
|
11
|
|
|
11
|
1
|
2803
|
my $self = shift; |
22
|
11
|
100
|
|
|
|
38
|
for (grep defined, @_) { return if _bad(); } |
|
20
|
|
|
|
|
41
|
|
23
|
10
|
|
|
|
|
36
|
return $self->SUPER::combine(@_); |
24
|
|
|
|
|
|
|
} |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
sub parse { |
27
|
8
|
|
|
8
|
1
|
2359
|
my $self = shift; |
28
|
8
|
|
|
|
|
34
|
for (map +$_, grep defined, @_) { |
29
|
7
|
|
|
|
|
14
|
chomp; |
30
|
7
|
100
|
|
|
|
18
|
return if _bad(); |
31
|
|
|
|
|
|
|
} |
32
|
7
|
|
|
|
|
29
|
return $self->SUPER::parse( @_ ); |
33
|
|
|
|
|
|
|
} |
34
|
|
|
|
|
|
|
|
35
|
2
|
|
|
2
|
|
42971
|
sub _bad { m{ [^\t\P{Cntrl}] }x; } # test $_ |
|
2
|
|
|
27
|
|
32
|
|
|
2
|
|
|
|
|
31
|
|
|
27
|
|
|
|
|
108
|
|
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
1; |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
__END__ |