diff options
author | MikalaiR <nikolay.romanovich@narod.ru> | 2016-02-17 17:19:09 +0000 |
---|---|---|
committer | MikalaiR <nikolay.romanovich@narod.ru> | 2016-02-17 17:19:09 +0000 |
commit | bf0a92db2f770c8fd4a5eed47893c660ac1e54ee (patch) | |
tree | 9f49382951374c6992618512c9f3910e020a4957 /plugins/MirLua/Modules/ffi/src/ffi.h | |
parent | 7a8fafbb2c8a2d1175c4f92b08d1b8c30f475a4a (diff) |
lua_ffi: VC2010 compilation fix
git-svn-id: http://svn.miranda-ng.org/main/trunk@16295 1316c22d-e87f-b044-9b9b-93d7a3e3ba9c
Diffstat (limited to 'plugins/MirLua/Modules/ffi/src/ffi.h')
-rw-r--r-- | plugins/MirLua/Modules/ffi/src/ffi.h | 27 |
1 files changed, 16 insertions, 11 deletions
diff --git a/plugins/MirLua/Modules/ffi/src/ffi.h b/plugins/MirLua/Modules/ffi/src/ffi.h index a66f43de4c..577956b11d 100644 --- a/plugins/MirLua/Modules/ffi/src/ffi.h +++ b/plugins/MirLua/Modules/ffi/src/ffi.h @@ -9,30 +9,35 @@ #pragma once
-#ifdef _MSC_VER
-#define _CRT_SECURE_NO_WARNINGS
-#endif
-
#define LUA_FFI_BUILD_AS_DLL
#include <stdint.h>
-#include <stdbool.h>
+
+#if _MSC_VER < 1800
+# include "msvc/stdbool.h"
+# include "msvc/inttypes.h"
+#else
+# include <stdbool.h>
+# include <inttypes.h>
+#endif
+
#include <stdlib.h>
#include <string.h>
#include <assert.h>
#ifdef __cplusplus
-extern "C" {
-# include "..\..\..\..\..\libs\liblua\src\lua.h"
-# include "..\..\..\..\..\libs\liblua\src\lauxlib.h"
-# include "..\..\..\..\..\libs\liblua\src\lualib.h"
-}
# define EXTERN_C extern "C"
+extern "C"
+{
#else
+# define EXTERN_C extern
+#endif
# include "..\..\..\..\..\libs\liblua\src\lua.h"
# include "..\..\..\..\..\libs\liblua\src\lauxlib.h"
# include "..\..\..\..\..\libs\liblua\src\lualib.h"
-# define EXTERN_C extern
+
+#ifdef __cplusplus
+}
#endif
#ifdef _WIN32
|