mirror of
https://github.com/geode-sdk/geode.git
synced 2025-03-24 03:39:56 -04:00
implement std::hash<std::filesystem::path> for everything but windows
This commit is contained in:
parent
7860cb05ef
commit
4f6492da08
1 changed files with 10 additions and 0 deletions
|
@ -13,6 +13,16 @@
|
|||
#include <charconv>
|
||||
#include <clocale>
|
||||
|
||||
// only windows seems to properly implement std::hash on std::filesystem::path
|
||||
#ifndef GEODE_IS_WINDOWS
|
||||
template <>
|
||||
struct std::hash<std::filesystem::path> {
|
||||
std::size_t operator()(std::filesystem::path const& path) const noexcept {
|
||||
return std::filesystem::hash_value(path);
|
||||
}
|
||||
};
|
||||
#endif
|
||||
|
||||
namespace geode {
|
||||
using ByteVector = std::vector<uint8_t>;
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue