xsubs/defined.xs

filter: Statementstmt 100% 4 / 4 Branchbran 62.5% 5 / 8 Conditioncond n/a MC/DCmcdc n/a Subroutinesub n/a Podpod n/a totaltotal 75.0% 9 / 12 CC 0 SCAR 0
CC
0
Cov
0%
CRAP 0
« xsubs/clone.xs ↑ Summary C.xs »
1 ################################################################################
2 #
3 # Copyright (c) 2002-2020 Marcus Holland-Moritz. All rights reserved.
4 # This program is free software; you can redistribute it and/or modify
5 # it under the same terms as Perl itself.
6 #
7 ################################################################################
8  
9  
10 ################################################################################
11 #
12 # METHOD: defined
13 #
14 # WRITTEN BY: Marcus Holland-Moritz ON: Feb 2006
15 # CHANGED BY: ON:
16 #
17 ################################################################################
18  
19 bool
20 CBC::defined(name)
21 const char *name
22  
23 PREINIT:
24 46 CBC_METHOD(defined);
25  
26 CODE:
27 CT_DEBUG_METHOD;
28  
29 /* TODO: probably we can do without parse data (would require special handling of the pp object) */
30 46 ▶ CHECK_PARSE_DATA;
Branch: 1 branch
BranchTrueFalseTotal
CHECK_PARSE_DATA; 6 40 46
31 40 ▶ CHECK_VOID_CONTEXT;
Branch: 2 branches
BranchTrueFalseTotal
CHECK_VOID_CONTEXT; 0 40 40
CHECK_VOID_CONTEXT; 0 0 0
32  
33 40 ▶ RETVAL = macro_is_defined(&THIS->cpi, name);
Branch: 1 branch
BranchTrueFalseTotal
RETVAL = macro_is_defined(&THIS->cpi, name); 28 12 40
34  
35 OUTPUT:
36 RETVAL
37  
« xsubs/clone.xs ↑ Summary C.xs »