aboutsummaryrefslogtreecommitdiff
path: root/ports/nanodbc/0004_unicode.patch
blob: a4def235c0cc77b8975832dc45cadf84c71450e9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
diff --git a/src/nanodbc.cpp b/src/nanodbc.cpp
index 8e02d4a..c408af7 100644
--- a/src/nanodbc.cpp
+++ b/src/nanodbc.cpp
@@ -90,7 +90,7 @@
     typedef std::u32string wide_string_type;
     #define NANODBC_CODECVT_TYPE std::codecvt_utf8
 #else
-    typedef std::u16string wide_string_type;
+    typedef std::wstring wide_string_type;
     #define NANODBC_CODECVT_TYPE std::codecvt_utf8_utf16
 #endif
 typedef wide_string_type::value_type wide_char_t;
diff --git a/src/nanodbc.h b/src/nanodbc.h
index f4e7b3d..bb7bacd 100644
--- a/src/nanodbc.h
+++ b/src/nanodbc.h
@@ -127,13 +127,13 @@ namespace nanodbc
 
 //! @}
 
-// You must explicitly request Unicode support by defining NANODBC_USE_UNICODE at compile time.
+#define NANODBC_USE_UNICODE 1
 #ifndef DOXYGEN
     #ifdef NANODBC_USE_UNICODE
         #ifdef NANODBC_USE_IODBC_WIDE_STRINGS
             typedef std::u32string string_type;
         #else
-            typedef std::u16string string_type;
+            typedef std::wstring string_type;
         #endif
     #else
         typedef std::string string_type;