|
42 | 42 | # include BOOST_REGEX_USER_CONFIG
|
43 | 43 |
|
44 | 44 | # include <boost/config.hpp>
|
| 45 | +# include <boost/predef.h> |
45 | 46 |
|
46 | 47 | #else
|
47 | 48 | /*
|
|
147 | 148 |
|
148 | 149 | /* disable our own file-iterators and mapfiles if we can't
|
149 | 150 | * support them: */
|
150 |
| -#if !defined(BOOST_HAS_DIRENT_H) && !(defined(_WIN32) && !defined(BOOST_REGEX_NO_W32)) |
151 |
| -# define BOOST_REGEX_NO_FILEITER |
| 151 | +#if defined(_WIN32) |
| 152 | +# if defined(BOOST_REGEX_NO_W32) || BOOST_PLAT_WINDOWS_STORE |
| 153 | +# define BOOST_REGEX_NO_FILEITER |
| 154 | +# endif |
| 155 | +#else // defined(_WIN32) |
| 156 | +# if !defined(BOOST_HAS_DIRENT_H) |
| 157 | +# define BOOST_REGEX_NO_FILEITER |
| 158 | +# endif |
152 | 159 | #endif
|
153 | 160 |
|
154 | 161 | /* backwards compatibitity: */
|
|
177 | 184 | * with MSVC and the /Zc:wchar_t option we place some extra unsigned short versions
|
178 | 185 | * of the non-inline functions in the library, so that users can still link to the lib,
|
179 | 186 | * irrespective of whether their own code is built with /Zc:wchar_t.
|
180 |
| - * Note that this does NOT WORK with VC10 when the C++ locale is in effect as |
| 187 | + * Note that this does NOT WORK with VC10 and VC14 when the C++ locale is in effect as |
181 | 188 | * the locale's <unsigned short> facets simply do not compile in that case.
|
| 189 | + * As we default to the C++ locale when compiling for the windows runtime we |
| 190 | + * skip in this case aswell. |
182 | 191 | */
|
183 |
| -#if defined(__cplusplus) && (defined(BOOST_MSVC) || defined(__ICL)) && !defined(BOOST_NO_INTRINSIC_WCHAR_T) && defined(BOOST_WINDOWS) && !defined(__SGI_STL_PORT) && !defined(_STLPORT_VERSION) && !defined(BOOST_RWSTD_VER) && ((_MSC_VER < 1600) || !defined(BOOST_REGEX_USE_CPP_LOCALE)) |
| 192 | +#if defined(__cplusplus) && \ |
| 193 | + (defined(BOOST_MSVC) || defined(__ICL)) && \ |
| 194 | + !defined(BOOST_NO_INTRINSIC_WCHAR_T) && \ |
| 195 | + defined(BOOST_WINDOWS) && \ |
| 196 | + !defined(__SGI_STL_PORT) && \ |
| 197 | + !defined(_STLPORT_VERSION) && \ |
| 198 | + !defined(BOOST_RWSTD_VER) && \ |
| 199 | + ((_MSC_VER < 1600) || !defined(BOOST_REGEX_USE_CPP_LOCALE)) && \ |
| 200 | + !BOOST_PLAT_WINDOWS_RUNTIME |
184 | 201 | # define BOOST_REGEX_HAS_OTHER_WCHAR_T
|
185 | 202 | # ifdef BOOST_MSVC
|
186 | 203 | # pragma warning(push)
|
|
278 | 295 | # define BOOST_REGEX_USE_C_LOCALE
|
279 | 296 | #endif
|
280 | 297 |
|
| 298 | +/* use C++ locale when targeting windows store */ |
| 299 | +#if BOOST_PLAT_WINDOWS_RUNTIME |
| 300 | +# define BOOST_REGEX_USE_CPP_LOCALE |
| 301 | +# define BOOST_REGEX_NO_WIN32_LOCALE |
| 302 | +#endif |
| 303 | + |
281 | 304 | /* Win32 defaults to native Win32 locale: */
|
282 |
| -#if defined(_WIN32) && !defined(BOOST_REGEX_USE_WIN32_LOCALE) && !defined(BOOST_REGEX_USE_C_LOCALE) && !defined(BOOST_REGEX_USE_CPP_LOCALE) && !defined(BOOST_REGEX_NO_W32) |
| 305 | +#if defined(_WIN32) && \ |
| 306 | + !defined(BOOST_REGEX_USE_WIN32_LOCALE) && \ |
| 307 | + !defined(BOOST_REGEX_USE_C_LOCALE) && \ |
| 308 | + !defined(BOOST_REGEX_USE_CPP_LOCALE) && \ |
| 309 | + !defined(BOOST_REGEX_NO_W32) && \ |
| 310 | + !defined(BOOST_REGEX_NO_WIN32_LOCALE) |
283 | 311 | # define BOOST_REGEX_USE_WIN32_LOCALE
|
284 | 312 | #endif
|
285 | 313 | /* otherwise use C++ locale if supported: */
|
|
0 commit comments