With gnu89:
/* share.h */
extern inline void f (void);
/* function.c */
void f (void) {}
/* main.c */
#include "share.h"
int main (int argc, char **argv) {
f ();
return 0;
}
With C99:
/* share.h */
static inline void f (void) {}
/* main.c */
#include "share.h"
int main (int argc, char **argv) {
f ();
return 0;
}
How to implement one definition of f() in function.c like in gnu89 but using C99 mode ?