comparison test/suite3/case.cc @ 604:90dfdac91b9b

- cleanups, made some arrays local to TUs, etc.
author Tassilo Philipp
date Wed, 21 Sep 2022 14:36:44 +0200
parents f5577f6bf97a
children 85b7a117b807
comparison
equal deleted inserted replaced
603:c1208587091c 604:90dfdac91b9b
27 27
28 #include "../../dyncall/dyncall.h" 28 #include "../../dyncall/dyncall.h"
29 #include "config.h" 29 #include "config.h"
30 #include "../../dyncall/dyncall_value.h" 30 #include "../../dyncall/dyncall_value.h"
31 31
32 DCValue mValue[NARGS]; 32 static DCValue mValue[NARGS];
33 33
34 void clearValues() { for(int i = 0;i<NARGS;++i) mValue[i].L = 0xCAFEBABEDEADC0DEULL; } 34 void clearValues() { for(int i = 0;i<NARGS;++i) mValue[i].L = 0xCAFEBABEDEADC0DEULL; }
35 35
36 template<typename T> void g(T value, int pos); 36 template<typename T> void g(T value, int pos);
37 37
86 #define VF8(id,A1,A2,A3,A4,A5,A6,A7,A8,S) reinterpret_cast<void(*)()>(S), 86 #define VF8(id,A1,A2,A3,A4,A5,A6,A7,A8,S) reinterpret_cast<void(*)()>(S),
87 #define VF9(id,A1,A2,A3,A4,A5,A6,A7,A8,A9,S) reinterpret_cast<void(*)()>(S), 87 #define VF9(id,A1,A2,A3,A4,A5,A6,A7,A8,A9,S) reinterpret_cast<void(*)()>(S),
88 #define VF10(id,A1,A2,A3,A4,A5,A6,A7,A8,A9,A10,S) reinterpret_cast<void(*)()>(S), 88 #define VF10(id,A1,A2,A3,A4,A5,A6,A7,A8,A9,A10,S) reinterpret_cast<void(*)()>(S),
89 89
90 typedef void (*fp)(); 90 typedef void (*fp)();
91 fp gFuncTable[] = { 91 static fp gFuncTable[] = {
92 #include "case.h" 92 #include "case.h"
93 }; 93 };
94 94
95 DCpointer getFunc(int x) { 95 DCpointer getFunc(int x) {
96 return (DCpointer) gFuncTable[x]; 96 return (DCpointer) gFuncTable[x];
97 } 97 }
98