xs/Index/Conflict.xs

filter: Statementstmt 100% 21 / 21 Branchbran 50.0% 3 / 6 Conditioncond n/a MC/DCmcdc n/a Subroutinesub n/a Podpod n/a totaltotal 88.8% 24 / 27 CC 0 SCAR 0
CC
0
Cov
0%
CRAP 0
« xs/Odb/Backend/Loose.xs ↑ Summary xs/Reflog.xs »
1 MODULE = Git::Raw PACKAGE = Git::Raw::Index::Conflict
2  
3 SV *
4 ours(self)
5 SV *self
6  
7 PREINIT:
8 Index_Conflict conflict;
9  
10 CODE:
11 2 conflict = GIT_SV_TO_PTR(Index::Conflict, self);
12  
13 2 RETVAL = &PL_sv_undef;
14  
15 2 ▶ if (conflict -> ours) {
Branch: 1 branch
BranchTrueFalseTotal
if (conflict -> ours) { 2 0 2
16 2 RETVAL = git_index_entry_to_sv(
17 2 conflict -> ours, NULL, GIT_SV_TO_MAGIC(self)
18 );
19 }
20  
21 OUTPUT: RETVAL
22  
23 SV *
24 ancestor(self)
25 SV *self
26  
27 PREINIT:
28 Index_Conflict conflict;
29  
30 CODE:
31 2 conflict = GIT_SV_TO_PTR(Index::Conflict, self);
32  
33 2 RETVAL = &PL_sv_undef;
34  
35 2 ▶ if (conflict -> ancestor) {
Branch: 1 branch
BranchTrueFalseTotal
if (conflict -> ancestor) { 2 0 2
36 2 RETVAL = git_index_entry_to_sv(
37 2 conflict -> ancestor, NULL, GIT_SV_TO_MAGIC(self)
38 );
39 }
40  
41 OUTPUT: RETVAL
42  
43 SV *
44 theirs(self)
45 SV *self
46  
47 PREINIT:
48 Index_Conflict conflict;
49  
50 CODE:
51 2 conflict = GIT_SV_TO_PTR(Index::Conflict, self);
52  
53 2 RETVAL = &PL_sv_undef;
54  
55 2 ▶ if (conflict -> theirs) {
Branch: 1 branch
BranchTrueFalseTotal
if (conflict -> theirs) { 2 0 2
56 2 RETVAL = git_index_entry_to_sv(
57 2 conflict -> theirs, NULL, GIT_SV_TO_MAGIC(self)
58 );
59 }
60  
61 OUTPUT: RETVAL
62  
63 void
64 DESTROY(self)
65 SV *self
66  
67 PREINIT:
68 Index_Conflict conflict;
69  
70 CODE:
71 2 conflict = GIT_SV_TO_PTR(Index::Conflict, self);
72 2 git_index_entry_free(conflict -> ours);
73 2 git_index_entry_free(conflict -> theirs);
74 2 git_index_entry_free(conflict -> ancestor);
75  
76 2 SvREFCNT_dec(GIT_SV_TO_MAGIC(self));
77 2 Safefree(conflict);
« xs/Odb/Backend/Loose.xs ↑ Summary xs/Reflog.xs »