xs/ops.xs

filter: Statementstmt 100% 21 / 21 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub n/a Podpod n/a totaltotal 100% 21 / 21 CC 0 SCAR 0
CC
0
Cov
0%
CRAP 0
« include/hamt/hamt_iter.h ↑ Summary
1 # The function forms of the reads, each in the class it reads. Called through
2 # a reference or with an ampersand they run as written here; a plain call is
3 # compiled into an op where perl allows it. The prototypes are what make the
4 # two agree.
5 #
6 # use HAMT::Map qw(hamt_map_get ...) or qw(:all): into the package the `use`
7 # was compiled in, which is the current statement's.
8  
9 MODULE = HAMT PACKAGE = HAMT::Map
10  
11 void
12 hamt_map_get(self, key)
13 SV *self
14 SV *key
15 PROTOTYPE: $$
16 CODE:
17 6 ST(0) = hamt_fn_map_get(aTHX_ self, key);
18 6 XSRETURN(1);
19  
20 void
21 hamt_map_exists(self, key)
22 SV *self
23 SV *key
24 PROTOTYPE: $$
25 CODE:
26 3 ST(0) = hamt_fn_map_exists(aTHX_ self, key);
27 3 XSRETURN(1);
28  
29 void
30 hamt_map_count(self)
31 SV *self
32 PROTOTYPE: $
33 CODE:
34 2 ST(0) = sv_2mortal(newSVuv(hamt_fn_map_count(aTHX_ self)));
35 2 XSRETURN(1);
36  
37 void
38 import(class, ...)
39 CODE:
40 23 hamt_fn_import(aTHX_ HAMT_FN_MAP, &ST(1), items - 1);
41 21 XSRETURN_EMPTY;
42  
43 MODULE = HAMT PACKAGE = HAMT::Set
44  
45 void
46 hamt_set_has(self, member)
47 SV *self
48 SV *member
49 PROTOTYPE: $$
50 CODE:
51 3 ST(0) = hamt_fn_set_has(aTHX_ self, member);
52 3 XSRETURN(1);
53  
54 void
55 hamt_set_count(self)
56 SV *self
57 PROTOTYPE: $
58 CODE:
59 2 ST(0) = sv_2mortal(newSVuv(hamt_fn_set_count(aTHX_ self)));
60 2 XSRETURN(1);
61  
62 void
63 import(class, ...)
64 CODE:
65 11 hamt_fn_import(aTHX_ HAMT_FN_SET, &ST(1), items - 1);
66 10 XSRETURN_EMPTY;
67  
68 MODULE = HAMT PACKAGE = HAMT::Vector
69  
70 void
71 hamt_vector_get(self, index)
72 SV *self
73 SV *index
74 PROTOTYPE: $$
75 CODE:
76 3 ST(0) = hamt_fn_vector_get(aTHX_ self, index);
77 3 XSRETURN(1);
78  
79 void
80 hamt_vector_count(self)
81 SV *self
82 PROTOTYPE: $
83 CODE:
84 2 ST(0) = sv_2mortal(newSVuv(hamt_fn_vector_count(aTHX_ self)));
85 2 XSRETURN(1);
86  
87 void
88 import(class, ...)
89 CODE:
90 16 hamt_fn_import(aTHX_ HAMT_FN_VECTOR, &ST(1), items - 1);
91 15 XSRETURN_EMPTY;
92  
93 BOOT:
94 29 hamt_ops_boot(aTHX);
« include/hamt/hamt_iter.h ↑ Summary