c-loggerLevel-types.inc

filter: Statementstmt 0.0% 0 / 53 Branchbran 0.0% 0 / 18 Conditioncond n/a MC/DCmcdc n/a Subroutinesub n/a Podpod n/a totaltotal 0.0% 0 / 71 CC 0 SCAR 0
CC
0
Cov
0%
CRAP 0
« c-event-types.inc ↑ Summary c-rulePropertyBitSet-types.inc »
1 static int
2 0 loggerLevel_constant_28 (pTHX_ const char *name, IV *iv_return) {
3 /* When generated this function returned values for the list of names given
4 here. However, subsequent manual editing may have added or removed some.
5 GENERICLOGGER_LOGLEVEL_ALERT GENERICLOGGER_LOGLEVEL_DEBUG
6 GENERICLOGGER_LOGLEVEL_ERROR GENERICLOGGER_LOGLEVEL_TRACE */
7 /* Offset 27 gives the best switch position. */
8 0 switch (name[27]) {
9 0 case 'E':
10 0 ▶ if (memEQ(name, "GENERICLOGGER_LOGLEVEL_TRAC", 27)) {
Branch: 1 branch
BranchTrueFalseTotal
if (memEQ(name, "GENERICLOGGER_LOGLEVEL_TRAC", 27)) { 0 0 0
11 /* E */
12 #if 1
13 0 *iv_return = GENERICLOGGER_LOGLEVEL_TRACE;
14 0 return PERL_constant_ISIV;
15 #else
16 return PERL_constant_NOTDEF;
17 #endif
18 }
19 0 break;
20 0 case 'G':
21 0 ▶ if (memEQ(name, "GENERICLOGGER_LOGLEVEL_DEBU", 27)) {
Branch: 1 branch
BranchTrueFalseTotal
if (memEQ(name, "GENERICLOGGER_LOGLEVEL_DEBU", 27)) { 0 0 0
22 /* G */
23 #if 1
24 0 *iv_return = GENERICLOGGER_LOGLEVEL_DEBUG;
25 0 return PERL_constant_ISIV;
26 #else
27 return PERL_constant_NOTDEF;
28 #endif
29 }
30 0 break;
31 0 case 'R':
32 0 ▶ if (memEQ(name, "GENERICLOGGER_LOGLEVEL_ERRO", 27)) {
Branch: 1 branch
BranchTrueFalseTotal
if (memEQ(name, "GENERICLOGGER_LOGLEVEL_ERRO", 27)) { 0 0 0
33 /* R */
34 #if 1
35 0 *iv_return = GENERICLOGGER_LOGLEVEL_ERROR;
36 0 return PERL_constant_ISIV;
37 #else
38 return PERL_constant_NOTDEF;
39 #endif
40 }
41 0 break;
42 0 case 'T':
43 0 ▶ if (memEQ(name, "GENERICLOGGER_LOGLEVEL_ALER", 27)) {
Branch: 1 branch
BranchTrueFalseTotal
if (memEQ(name, "GENERICLOGGER_LOGLEVEL_ALER", 27)) { 0 0 0
44 /* T */
45 #if 1
46 0 *iv_return = GENERICLOGGER_LOGLEVEL_ALERT;
47 0 return PERL_constant_ISIV;
48 #else
49 return PERL_constant_NOTDEF;
50 #endif
51 }
52 0 break;
53 }
54 0 return PERL_constant_NOTFOUND;
55 }
56 static int
57 0 loggerLevel_constant (pTHX_ const char *name, STRLEN len, IV *iv_return) {
58 /* Initially switch on the length of the name. */
59 /* When generated this function returned values for the list of names given
60 in this section of perl code. Rather than manually editing these functions
61 to add or remove constants, which would result in this comment and section
62 of code becoming inaccurate, we recommend that you edit this section of
63 code, and use it to regenerate a new set of constant functions which you
64 then use to replace the originals.
65  
66 Regenerate these constant functions by feeding this entire source file to
67 perl -x
68  
69 #!/usr/local/bin/perl -w
70 use ExtUtils::Constant qw (constant_types C_constant XS_constant);
71  
72 my $types = {map {($_, 1)} qw(IV)};
73 my @names = (qw(GENERICLOGGER_LOGLEVEL_ALERT GENERICLOGGER_LOGLEVEL_CRITICAL
74 GENERICLOGGER_LOGLEVEL_DEBUG GENERICLOGGER_LOGLEVEL_EMERGENCY
75 GENERICLOGGER_LOGLEVEL_ERROR GENERICLOGGER_LOGLEVEL_INFO
76 GENERICLOGGER_LOGLEVEL_NOTICE GENERICLOGGER_LOGLEVEL_TRACE
77 GENERICLOGGER_LOGLEVEL_WARNING));
78  
79 print constant_types(), "\n"; # macro defs
80 foreach (C_constant ("MarpaX::ESLIF::Logger::Level", 'loggerLevel_constant', 'IV', $types, undef, 3, @names) ) {
81 print $_, "\n"; # C constant subs
82 }
83 print "\n#### XS Section:\n";
84 print XS_constant ("MarpaX::ESLIF::Logger::Level", $types);
85 __END__
« c-event-types.inc ↑ Summary c-rulePropertyBitSet-types.inc »