fix link errors on compilers with strict "extern" enforcement
[rofl0r-openbor.git] / stringswitch_impl_lcm_cmdcandamage.c
blob3c3c07a2923033cdbdbae5c91ea2eb05f4141c31
1 typedef enum {
2 stringswitch_enumerator_default_member_name(lcm_cmdcandamage),
3 stringswitch_enumerator_member_name(lcm_cmdcandamage, npc),
4 stringswitch_enumerator_member_name(lcm_cmdcandamage, shot),
5 stringswitch_enumerator_member_name(lcm_cmdcandamage, enemy),
6 stringswitch_enumerator_member_name(lcm_cmdcandamage, player),
7 stringswitch_enumerator_member_name(lcm_cmdcandamage, ground),
8 stringswitch_enumerator_member_name(lcm_cmdcandamage, obstacle),
9 } stringswitch_enumerator_name(lcm_cmdcandamage);
11 static int stringswitch_enumerator_eval_func(lcm_cmdcandamage) (char* str, size_t l) {
12 switch(l) {
13 case 3:
14 if(str[0]!='n') goto main_default;
15 if(str[1]!='p') goto main_default;
16 if(str[2]!='c') goto main_default;
17 return stringswitch_enumerator_member_name(lcm_cmdcandamage, npc);
18 case 4:
19 if(str[0]!='s') goto main_default;
20 if(str[1]!='h') goto main_default;
21 if(str[2]!='o') goto main_default;
22 if(str[3]!='t') goto main_default;
23 return stringswitch_enumerator_member_name(lcm_cmdcandamage, shot);
24 case 5:
25 if(str[0]!='e') goto main_default;
26 if(str[1]!='n') goto main_default;
27 if(str[2]!='e') goto main_default;
28 if(str[3]!='m') goto main_default;
29 if(str[4]!='y') goto main_default;
30 return stringswitch_enumerator_member_name(lcm_cmdcandamage, enemy);
31 case 6:
32 switch(str[0]) {
33 case 'p':
34 if(str[1]!='l') goto main_default;
35 if(str[2]!='a') goto main_default;
36 if(str[3]!='y') goto main_default;
37 if(str[4]!='e') goto main_default;
38 if(str[5]!='r') goto main_default;
39 return stringswitch_enumerator_member_name(lcm_cmdcandamage, player);
40 case 'g':
41 if(str[1]!='r') goto main_default;
42 if(str[2]!='o') goto main_default;
43 if(str[3]!='u') goto main_default;
44 if(str[4]!='n') goto main_default;
45 if(str[5]!='d') goto main_default;
46 return stringswitch_enumerator_member_name(lcm_cmdcandamage, ground);
47 default: goto main_default;
49 case 8:
50 if(str[0]!='o') goto main_default;
51 if(str[1]!='b') goto main_default;
52 if(str[2]!='s') goto main_default;
53 if(str[3]!='t') goto main_default;
54 if(str[4]!='a') goto main_default;
55 if(str[5]!='c') goto main_default;
56 if(str[6]!='l') goto main_default;
57 if(str[7]!='e') goto main_default;
58 return stringswitch_enumerator_member_name(lcm_cmdcandamage, obstacle);
59 default:
60 main_default:
61 return stringswitch_enumerator_default_member_name(lcm_cmdcandamage);