Make NK_API 'static inline' for NK_PRIVATE version

Fixed definition for C89 standard
This commit is contained in:
Anton Bondarev 2017-02-13 13:39:56 +03:00
parent 6fa8424d6e
commit aac2d71740
1 changed files with 11 additions and 5 deletions

View File

@ -271,11 +271,17 @@ extern "C" {
* ===============================================================
*/
#ifndef NK_API
#ifdef NK_PRIVATE
#define NK_API static inline
#else
#define NK_API extern
#endif
#ifdef NK_PRIVATE
#if (defined(__STDC_VERSION__) && (__STDC_VERSION__ >= 199409L))
#define NK_API static inline
#elif defined(__cplusplus)
#define NK_API static inline
#else
#define NK_API static
#endif
#else
#define NK_API extern
#endif
#endif
#define NK_INTERN static