Commit 1a248650520c9ab6c17e06d00a9bbef26f788177

Martin Mitas 2019-03-16T09:39:00

Fix building with MD4C_USE_UTF16.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
diff --git a/md4c/md4c.h b/md4c/md4c.h
index 10cba67..98118e7 100644
--- a/md4c/md4c.h
+++ b/md4c/md4c.h
@@ -30,10 +30,12 @@
     extern "C" {
 #endif
 
-/* Magic to support UTF-16. */
 #if defined MD4C_USE_UTF16
+    /* Magic to support UTF-16. Not that in order to use it, you have to define
+     * the macro MD4C_USE_UTF16 both when building MD4C as well as when
+     * including this header in your code. */
     #ifdef _WIN32
-        #include <wchar.h>
+        #include <windows.h>
         typedef WCHAR       MD_CHAR;
     #else
         #error MD4C_USE_UTF16 is only supported on Windows.