commit d5535bd57a703e26c397f3efc4747a079954c87d
parent 63a92c08628c89346be521b5de8cc0685cfd4b2f
Author: Martin Mitas <mity@morous.org>
Date: Tue, 4 Oct 2016 00:36:02 +0200
For MSVC, #define inline __inline.
This fixes build in MSVC.
Diffstat:
1 file changed, 8 insertions(+), 0 deletions(-)
diff --git a/md4c/md4c.c b/md4c/md4c.c
@@ -35,6 +35,14 @@
*** Miscellaneous Stuff ***
*****************************/
+#ifdef _MSC_VER
+ /* MSVC does not understand "inline" when building as pure C (not C++).
+ * However it understands "__inline" */
+ #ifndef __cplusplus
+ #define inline __inline
+ #endif
+#endif
+
/* Magic to support UTF16-LE (i.e. what is called Unicode among Windows
* developers) input/output on Windows. */
#ifdef _T