File Coverage

blib/arch/XS/Framework.pm
Criterion Covered Total %
statement 24 24 100.0
branch n/a
condition n/a
subroutine 9 9 100.0
pod n/a
total 33 33 100.0


line stmt bran cond sub pod time code
1             package XS::Framework;
2 36     36   280578 use 5.018;
  36         310  
3 36     36   159 use Config;
  36         52  
  36         972  
4 36     36   12571 use next::XS;
  36         246956  
  36         1022  
5 36     36   13032 use XS::libpanda;
  36         49364  
  36         915  
6 36     36   11851 use XS::ErrorCode();
  36         88  
  36         757  
7 36     36   12227 use XS::STL::ErrorCode();
  36         78  
  36         578  
8 36     36   11916 use XS::STL::ErrorCategory();
  36         79  
  36         1773  
9              
10             our $VERSION = '1.3.2';
11              
12             # threads::shared doesn't respect the fact that PL_destroyhook might be in use by other modules and doesn't proxy call to next hook
13             # so that we must hook after threads::shared
14             if ($Config{useithreads}) {
15             require threads;
16             require threads::shared;
17 36     36   197 no warnings 'redefine';
  36         1560  
  36         8470  
18             my $orig_threads_create = \&threads::create;
19             *threads::create = sub {
20             __at_thread_create();
21             goto &$orig_threads_create;
22             };
23             }
24              
25             XS::Loader::load();
26              
27             END {
28 36     36   30373 __at_perl_destroy();
29             }
30              
31             1;