Skip to content

The project does not compile with GCC 7 #28

@chfast

Description

@chfast

Describe the bug

/home/builder/build/test/bench/filesystem.hpp: In instantiation of 'ghc::filesystem::path::path(const Source&, ghc::filesystem::path::format) [with Source = std::basic_string_view<char>; <template-parameter-1-2> = ghc::filesystem::path]':
/home/builder/build/test/bench/filesystem.hpp:2409:35:   required from here
/home/builder/build/test/bench/filesystem.hpp:1455:27: error: no matching function for call to 'toUtf8(const std::basic_string_view<char>&)'
     : _path(detail::toUtf8(source))
             ~~~~~~~~~~~~~~^~~~~~~~
/home/builder/build/test/bench/filesystem.hpp:1342:20: note: candidate: template<class charT, class traits, class Alloc, typename std::enable_if<(sizeof (charT) == 1), int>::type size> std::__cxx11::string ghc::filesystem::detail::toUtf8(const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>&)
 inline std::string toUtf8(const std::basic_string<charT, traits, Alloc>& unicodeString)
                    ^~~~~~
/home/builder/build/test/bench/filesystem.hpp:1342:20: note:   template argument deduction/substitution failed:
/home/builder/build/test/bench/filesystem.hpp:1455:27: note:   'const std::basic_string_view<char>' is not derived from 'const std::__cxx11::basic_string<_CharT, _Traits, _Alloc>'
     : _path(detail::toUtf8(source))
             ~~~~~~~~~~~~~~^~~~~~~~

To Reproduce
Compile with G++ 7 on Debian.

Expected behavior
Compiles.

Additional context
The GCC7 seems to be missing string_view or is not included.

Metadata

Metadata

Assignees

No one assigned

    Labels

    duplicateThis issue or pull request already exists

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions