Index: boost/iostreams/detail/path.hpp =================================================================== --- boost/iostreams/detail/path.hpp (版本 72317) +++ boost/iostreams/detail/path.hpp (工作副本) @@ -50,10 +50,16 @@ template explicit path(const Path& p, typename Path::external_string_type* = 0) { - typedef typename Path::external_string_type string_type; - init(p, boost::type()); + init(p.external_file_string()); } + // Constructor taking a boost::filesystem3::path (boost filesystem v3) + template + explicit path(const Path& p, typename Path::string_type* = 0) + { + init(p.native()); + } + // Copy constructor path(const path& p) : narrow_(p.narrow_), wide_(p.wide_), is_wide_(p.is_wide_) @@ -111,19 +117,17 @@ path(const std::wstring&); path& operator=(const std::wstring&); - template - void init(const Path& p, boost::type) + void init(std::string const& file_path) { - narrow_ = p.external_file_string(); + narrow_ = file_path; wide_.clear(); is_wide_ = false; } - template - void init(const Path& p, boost::type) + void init(std::wstring const& file_path) { narrow_.clear(); - wide_ = p.external_file_string(); + wide_ = file_path; is_wide_ = true; }