Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enhance test convertible_to_path_and_strings for all char types #327

Closed
wants to merge 1 commit into from
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 9 additions & 8 deletions test/path_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -161,15 +161,16 @@ class convertible_to_path_and_strings
}

operator fs::path() const { return m_path; }
operator const fs::path::value_type*() const
{
#if defined(BOOST_WINDOWS_API)
return L"[invalid path]";
#else
return "[invalid path]";
operator const char*() const { return "[invalid path]"; }
operator const wchar_t*() const { return L"[invalid path]"; }
operator std::string() const { return "[invalid path]"; }
operator std::wstring() const { return L"[invalid path]"; }
#if !defined(BOOST_NO_CXX17_HDR_STRING_VIEW)
operator std::string_view() const { return "[invalid path]"; }
operator std::wstring_view() const { return L"[invalid path]"; }
#endif
}
operator fs::path::string_type() const { return fs::path::string_type(static_cast< const fs::path::value_type* >(*this)); }
operator boost::basic_string_view< char, std::char_traits< char > >() const { return "[invalid path]"; }
operator boost::basic_string_view< wchar_t, std::char_traits< wchar_t > >() const { return L"[invalid path]"; }
};


Expand Down