File Coverage

blib/lib/B/Tap.pm
Criterion Covered Total %
statement 22 23 95.6
branch 1 2 50.0
condition n/a
subroutine 8 9 88.8
pod 1 3 33.3
total 32 37 86.4


line stmt bran cond sub pod time code
1             package B::Tap;
2 7     7   288133 use 5.014000;
  7         65  
3 7     7   36 use strict;
  7         12  
  7         148  
4 7     7   33 use warnings;
  7         13  
  7         378  
5              
6             our $VERSION = "0.16";
7              
8 7     7   3592 use parent qw(Exporter);
  7         2258  
  7         41  
9              
10             our @EXPORT = qw(tap);
11             our @EXPORT_OK = qw(G_ARRAY G_VOID G_SCALAR);
12             our %EXPORT_TAGS = (
13             'all' => [@EXPORT, @EXPORT_OK],
14             );
15              
16 7     7   663 use Carp ();
  7         13  
  7         120  
17              
18 7     7   33 use XSLoader;
  7         12  
  7         1327  
19             XSLoader::load(__PACKAGE__, $VERSION);
20              
21             sub tap {
22 6     6 1 1953 my ($op, $root_op, $buf) = @_;
23 6 50       21 Carp::croak("Third argument should be ArrayRef") unless ref $buf eq 'ARRAY';
24 6         64 _tap($$op, $$root_op, $buf);
25             }
26              
27             # tweaks for custom ops.
28             {
29             sub B::Deparse::pp_b_tap_tap {
30 2     2 0 14784 my ($self, $op) = @_;
31 2         1146 $self->deparse($op->first);
32             };
33             sub B::Deparse::pp_b_tap_push_sv {
34 0     0 0   '';
35             }
36             }
37              
38             1;
39             __END__