GMQCC_WARN macro

This commit is contained in:
Wolfgang (Blub) Bumiller 2012-04-27 12:35:59 +02:00
parent 4b6659bfe1
commit 348243ddf6

11
gmqcc.h
View file

@ -58,6 +58,17 @@
# endif
# endif /* !__cplusplus */
/*
* Of some functions which are generated we want to make sure
* that the result isn't ignored. To find such function calls,
* we use this macro.
*/
#if defined(__GNUC__) || defined(__CLANG__)
# define GMQCC_WARN __attribute__((warn_unused_result))
#else
# define GMQCC_WARN
#endif
/*
* stdint.h and inttypes.h -less subset
* for systems that don't have it, which we must