Hi,
I get the following warning when compiling libev:
libev-4.33/ev.c:2143:31: warning: ‘ev_default_loop_ptr’ initialized and
declared ‘extern’
2143 | EV_API_DECL struct ev_loop *ev_default_loop_ptr = 0; /* needs
to be initialised to make it a definition despite extern */
| ^~~~~~~~~~~~~~~~~~~
I don't see that EV_API_DECL is necessary in ev.c. Without EV_API_DECL,
the warning would not be issued.
If this is about hiding all API in case of EV_API_STATIC, then maybe
there should be an EV_API_HIDE declared like this:
#if EV_API_STATIC
#define EV_API_HIDE static
#else
#define EV_API_HIDE
#endif
This could be used inside ev.c to hide the ev_default_loop_ptr.
Best regards,
Christian Wendt
_______________________________________________
libev mailing list
libev@lists.schmorp.de
http://lists.schmorp.de/mailman/listinfo/libev