mirror of
https://github.com/trapexit/mergerfs.git
synced 2026-10-26 19:01:56 -04:00
Workaround older gcc bug with namespacing std::hash
This commit is contained in:
parent
cdceade1ae
commit
26fd11cb4d
2 changed files with 15 additions and 51 deletions
|
|
@ -19,6 +19,7 @@
|
|||
#include "fs_wait_for_mount.hpp"
|
||||
#include "syslog.hpp"
|
||||
|
||||
#include <functional>
|
||||
#include <thread>
|
||||
#include <unordered_set>
|
||||
|
||||
|
|
@ -30,15 +31,18 @@ namespace fs
|
|||
|
||||
constexpr std::chrono::milliseconds SLEEP_DURATION = std::chrono::milliseconds(333);
|
||||
|
||||
template<>
|
||||
struct std::hash<fs::Path>
|
||||
namespace std
|
||||
{
|
||||
std::size_t
|
||||
operator()(fs::Path const &path_) const noexcept
|
||||
template<>
|
||||
struct hash<fs::Path>
|
||||
{
|
||||
return std::hash<std::string>{}(path_.string());
|
||||
}
|
||||
};
|
||||
std::size_t
|
||||
operator()(fs::Path const &path_) const noexcept
|
||||
{
|
||||
return std::hash<std::string>{}(path_.string());
|
||||
}
|
||||
};
|
||||
}
|
||||
|
||||
static
|
||||
void
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue