Fix --with-latest-c++ build against libstdc++ 16
(e.g., libstdc++-devel-16.1.1-2.fc44.x86_64) after f320d95d89ecc9bea81182795969f83b05ec903c "Avoid deprecated std::filesystem::path::string", > In file included from engine/codemaker/source/netmaker/netproduce.cxx:19: > engine/codemaker/source/netmaker/csharpfile.hxx: In member function ‘std::string CSharpFile::getPath() const’: > engine/codemaker/source/netmaker/csharpfile.hxx:31:27: error: ‘const class std::filesystem::__cxx11::path’ has no member named ‘display_string’ > 31 | return m_filePath.display_string(); > | ^~~~~~~~~~~~~~ etc. Signed-off-by: Stephan Bergmann <stephan.bergmann@collabora.com> Change-Id: Ib51f9e0d0e1f902726f0d68a11fe28110388ef6a Reviewed-on: https://gerrit.collaboraoffice.com/c/online/+/6554 Tested-by: Jenkins CPCI <releng@collaboraoffice.com> Reviewed-by: Michael Stahl <michael.stahl@collabora.com> (cherry picked from commit 63e9ab3b87cc5a793c8733e375dc86d99419a88d) Reviewed-on: https://gerrit.libreoffice.org/c/core/+/208277 Tested-by: Jenkins Reviewed-by: Xisco Fauli <xiscofauli@libreoffice.org>
This commit is contained in:
committed by
Xisco Fauli
parent
3552e250f4
commit
727d62727e
@@ -27,7 +27,7 @@ public:
|
||||
public:
|
||||
std::string getPath() const
|
||||
{
|
||||
#if defined __cpp_lib_format_path
|
||||
#if defined __cpp_lib_format_path && __cpp_lib_format_path >= 202506L
|
||||
return m_filePath.display_string();
|
||||
#else
|
||||
return m_filePath.string<char>();
|
||||
|
||||
@@ -25,7 +25,7 @@ RustFile::RustFile(std::string_view directory, std::string_view typeName)
|
||||
|
||||
std::string RustFile::getPath() const
|
||||
{
|
||||
#if defined __cpp_lib_format_path
|
||||
#if defined __cpp_lib_format_path && __cpp_lib_format_path >= 202506L
|
||||
return m_filePath.display_string();
|
||||
#else
|
||||
return m_filePath.string<char>();
|
||||
@@ -461,7 +461,7 @@ CppFile::CppFile(std::string_view directory, std::string_view typeName, std::str
|
||||
|
||||
std::string CppFile::getPathString() const
|
||||
{
|
||||
#if defined __cpp_lib_format_path
|
||||
#if defined __cpp_lib_format_path && __cpp_lib_format_path >= 202506L
|
||||
return m_filePath.display_string();
|
||||
#else
|
||||
return m_filePath.string<char>();
|
||||
|
||||
Reference in New Issue
Block a user