line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package FFI::Platypus::Lang::Raw; |
2
|
|
|
|
|
|
|
|
3
|
8
|
|
|
8
|
|
211663
|
use strict; |
|
8
|
|
|
|
|
25
|
|
|
8
|
|
|
|
|
243
|
|
4
|
8
|
|
|
8
|
|
42
|
use warnings; |
|
8
|
|
|
|
|
16
|
|
|
8
|
|
|
|
|
275
|
|
5
|
8
|
|
|
8
|
|
47
|
use base qw( FFI::Platypus::Lang::C ); |
|
8
|
|
|
|
|
15
|
|
|
8
|
|
|
|
|
2745
|
|
6
|
|
|
|
|
|
|
|
7
|
|
|
|
|
|
|
# ABSTRACT: Types for use with FFI::Platypus::Legacy::Raw |
8
|
|
|
|
|
|
|
our $VERSION = '0.04'; # VERSION |
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
my %types; |
12
|
|
|
|
|
|
|
sub native_type_map |
13
|
|
|
|
|
|
|
{ |
14
|
1230
|
|
|
1230
|
1
|
334638
|
my $class = shift; |
15
|
1230
|
100
|
|
|
|
2161
|
unless(%types) |
16
|
|
|
|
|
|
|
{ |
17
|
|
|
|
|
|
|
%types = ( |
18
|
8
|
|
|
|
|
17
|
%{ $class->SUPER::native_type_map }, |
|
8
|
|
|
|
|
59
|
|
19
|
|
|
|
|
|
|
'v' => 'void', |
20
|
|
|
|
|
|
|
'x' => 'sint64', |
21
|
|
|
|
|
|
|
'X' => 'uint64', |
22
|
|
|
|
|
|
|
'i' => 'sint32', |
23
|
|
|
|
|
|
|
'I' => 'sint64', |
24
|
|
|
|
|
|
|
'z' => 'sint16', |
25
|
|
|
|
|
|
|
'Z' => 'uint16', |
26
|
|
|
|
|
|
|
'c' => 'sint8', |
27
|
|
|
|
|
|
|
'C' => 'uint8', |
28
|
|
|
|
|
|
|
'f' => 'float', |
29
|
|
|
|
|
|
|
'd' => 'double', |
30
|
|
|
|
|
|
|
's' => 'string', |
31
|
|
|
|
|
|
|
); |
32
|
|
|
|
|
|
|
} |
33
|
1230
|
|
|
|
|
7726
|
$types{l} = $types{'long'}; |
34
|
1230
|
|
|
|
|
1723
|
$types{L} = $types{'unsigned long'}; |
35
|
1230
|
|
|
|
|
2388
|
\%types; |
36
|
|
|
|
|
|
|
} |
37
|
|
|
|
|
|
|
|
38
|
|
|
|
|
|
|
1; |
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
__END__ |