diff options
author | Andreas Schneider <asn@cryptomilk.org> | 2014-04-11 15:43:12 +0200 |
---|---|---|
committer | Andreas Schneider <asn@cryptomilk.org> | 2014-04-11 15:43:46 +0200 |
commit | c835170c575a71d4e7666da9c123c3ce2c908c22 (patch) | |
tree | 9ae9226cd24c68d99365adbfb0b6d5b98482deff | |
parent | 5988e5e27e21c79199677d24fb3ff2bf93677a19 (diff) | |
download | cmocka-c835170c575a71d4e7666da9c123c3ce2c908c22.tar.gz cmocka-c835170c575a71d4e7666da9c123c3ce2c908c22.tar.xz cmocka-c835170c575a71d4e7666da9c123c3ce2c908c22.zip |
cmocka: Define inline if not defined with MSVC.
-rw-r--r-- | include/cmocka.h | 19 |
1 files changed, 13 insertions, 6 deletions
diff --git a/include/cmocka.h b/include/cmocka.h index db1d74a..ed5965c 100644 --- a/include/cmocka.h +++ b/include/cmocka.h @@ -17,15 +17,22 @@ #define CMOCKA_H_ #ifdef _WIN32 -#if _MSC_VER < 1500 -#ifdef __cplusplus +# ifdef _MSC_VER + +# ifndef inline +#define inline __inline +# endif /* inline */ + +# if _MSC_VER < 1500 +# ifdef __cplusplus extern "C" { -#endif /* __cplusplus */ +# endif /* __cplusplus */ int __stdcall IsDebuggerPresent(); -#ifdef __cplusplus +# ifdef __cplusplus } /* extern "C" */ -#endif /* __cplusplus */ -#endif /* _MSC_VER < 1500 */ +# endif /* __cplusplus */ +# endif /* _MSC_VER < 1500 */ +# endif /* _MSC_VER */ #endif /* _WIN32 */ /* |