gcc - Is it possible to have a weak enum? -


i'm using gcc, , distributing object file may used in conjunction third party code. have looks this:

void fn3rdparty(int bar) __attribute ((weak));  void fn(void) {     if(fn3rdparty)         fn3rdparty(some_enum); } 

where some_enum enum , defined third party code if present. tried declaring some_enum weak int, gcc complains type redefined. i'm wondering if there's way around this? (i'd avoid having 1 .o file use software, , used without).

john


Comments

Popular posts from this blog

css - I want to align grid in center -

Contact Form PHP Email Script -

python - SWIG function not printing output -