fix MinGW's compiler errors
This commit is contained in:
parent
8d4a734272
commit
abfde4e77c
@ -116,8 +116,6 @@
|
|||||||
# define _enable_std_clamp
|
# define _enable_std_clamp
|
||||||
# endif
|
# endif
|
||||||
|
|
||||||
#elif defined(NANA_MINGW)
|
|
||||||
# define STD_THREAD_NOT_SUPPORTED
|
|
||||||
#elif defined(__clang__) //Clang
|
#elif defined(__clang__) //Clang
|
||||||
|
|
||||||
#include <iosfwd> //Introduces some implement-specific flags of ISO C++ Library
|
#include <iosfwd> //Introduces some implement-specific flags of ISO C++ Library
|
||||||
@ -132,9 +130,6 @@
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
# define _enable_std_clamp
|
|
||||||
|
|
||||||
#elif defined(__GNUC__) //GCC
|
#elif defined(__GNUC__) //GCC
|
||||||
|
|
||||||
#include <iosfwd> //Introduces some implement-specific flags of ISO C++ Library
|
#include <iosfwd> //Introduces some implement-specific flags of ISO C++ Library
|
||||||
@ -190,8 +185,20 @@
|
|||||||
#endif
|
#endif
|
||||||
#endif
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
#endif
|
||||||
|
|
||||||
# define _enable_std_clamp
|
//Assume the std::thread is not implement on MinGW
|
||||||
|
//But some toolchains may implement std::thread.
|
||||||
|
#ifdef NANA_MINGW
|
||||||
|
# ifndef STD_THREAD_NOT_SUPPORTED
|
||||||
|
# define STD_THREAD_NOT_SUPPORTED
|
||||||
|
# endif
|
||||||
|
#endif
|
||||||
|
|
||||||
|
#if (!defined(__cpp_lib_clamp)) || (__cpp_lib_clamp < 201603)
|
||||||
|
# ifndef _enable_std_clamp
|
||||||
|
# define _enable_std_clamp
|
||||||
|
# endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
||||||
|
@ -51,7 +51,7 @@ namespace nana
|
|||||||
|
|
||||||
truetype(const path_type& filename)
|
truetype(const path_type& filename)
|
||||||
{
|
{
|
||||||
std::ifstream ifs{ filename, std::ios::binary };
|
std::ifstream ifs(filename.string(), std::ios::binary);
|
||||||
if (!ifs.is_open())
|
if (!ifs.is_open())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user