mirror of
https://git.mirrors.martin98.com/https://github.com/gulrak/filesystem
synced 2025-06-04 11:13:58 +08:00
refs #17, fix for issues with mingw
This commit is contained in:
parent
e4e6246eaa
commit
d80948287e
@ -927,7 +927,7 @@ public:
|
||||
const basic_filebuf& operator=(const basic_filebuf&) = delete;
|
||||
basic_filebuf<charT, traits>* open(const path& p, std::ios_base::openmode mode)
|
||||
{
|
||||
#if defined(GHC_OS_WINDOWS) && defined(_MSC_VER)
|
||||
#if defined(GHC_OS_WINDOWS) && && !defined(__GNUC__)
|
||||
return std::basic_filebuf<charT, traits>::open(p.wstring().c_str(), mode) ? this : 0;
|
||||
#else
|
||||
return std::basic_filebuf<charT, traits>::open(p.c_str(), mode) ? this : 0;
|
||||
@ -940,7 +940,7 @@ class basic_ifstream : public std::basic_ifstream<charT, traits>
|
||||
{
|
||||
public:
|
||||
basic_ifstream() {}
|
||||
#if defined(GHC_OS_WINDOWS) && defined(_MSC_VER)
|
||||
#if defined(GHC_OS_WINDOWS) && && !defined(__GNUC__)
|
||||
explicit basic_ifstream(const path& p, std::ios_base::openmode mode = std::ios_base::in)
|
||||
: std::basic_ifstream<charT, traits>(p.wstring().c_str(), mode)
|
||||
{
|
||||
@ -963,7 +963,7 @@ class basic_ofstream : public std::basic_ofstream<charT, traits>
|
||||
{
|
||||
public:
|
||||
basic_ofstream() {}
|
||||
#if defined(GHC_OS_WINDOWS) && defined(_MSC_VER)
|
||||
#if defined(GHC_OS_WINDOWS) && !defined(__GNUC__)
|
||||
explicit basic_ofstream(const path& p, std::ios_base::openmode mode = std::ios_base::out)
|
||||
: std::basic_ofstream<charT, traits>(p.wstring().c_str(), mode)
|
||||
{
|
||||
@ -986,7 +986,7 @@ class basic_fstream : public std::basic_fstream<charT, traits>
|
||||
{
|
||||
public:
|
||||
basic_fstream() {}
|
||||
#if defined(GHC_OS_WINDOWS) && defined(_MSC_VER)
|
||||
#if defined(GHC_OS_WINDOWS) && !defined(__GNUC__)
|
||||
explicit basic_fstream(const path& p, std::ios_base::openmode mode = std::ios_base::in | std::ios_base::out)
|
||||
: std::basic_fstream<charT, traits>(p.wstring().c_str(), mode)
|
||||
{
|
||||
|
Loading…
x
Reference in New Issue
Block a user