6 #define MAX_INIT_RECORDS 10000
19 void AddFunction(void (*func
)(void));
20 void AddFunction(bool (*func
)(void));
21 void AddFunction(void *func
);
25 InitRecord
*fFunctions
[MAX_INIT_RECORDS
];
26 int fCount
; // counting on behavior of auto-initilization to 0
32 InitAdder(InitList
*initlist
, void (*func
)(void));
33 InitAdder(InitList
*initlist
, bool (*func
)(void));
34 InitAdder(InitList
&initlist
, void (*func
)(void));
35 InitAdder(InitList
&initlist
, bool (*func
)(void));
38 #define INITFUNC(TARGET) \
39 static void __InitFunc(void); \
40 static InitAdder _ia(TARGET, __InitFunc); \
41 static void __InitFunc(void) \