#include <stdio.h>
static int Var1;
static FUNC()
{
//do stuff with var
}
void CALL_FUNC()
{
//call FUNC
//do stuff
}
void fc1(void)
{
CALL_FUNC();
}
void fc2(void)
{
CALL_FUNC();
}
void fc3(void)
{
CALL_FUNC();
}
//etc.
void main()
{
}
goal is to break the fc1, fc2 and others into different files and at the same time keep the static-ness of the var1 and FUNC().
need ideas how to do this best to avoid violation of C rules?. creating a .c and put the var1, func() and call_func() in it and call the call_func() from other files is the best way I know so far.