mirror of
https://github.com/mfontanini/libtins
synced 2026-01-27 12:14:26 +01:00
Fix hash<IPv4/6Address> build issues in VC
* fixed compile failure due to macro * add functional to cxxstd.h to try to fix mac * clang bug identified, moving functional include to later * last step, move hash def to header * avoid allocation on hash * set ipv6 back to string hash
This commit is contained in:
committed by
Matias Fontanini
parent
e48f64daac
commit
a7dd867503
@@ -152,13 +152,3 @@ IPv6Address operator&(const IPv6Address& lhs, const IPv6Address& rhs) {
|
||||
}
|
||||
|
||||
} // Tins
|
||||
|
||||
#if TINS_IS_CXX11
|
||||
namespace std {
|
||||
|
||||
size_t hash<Tins::IPv6Address>::operator()(const Tins::IPv6Address& addr) const {
|
||||
return std::hash<string>()(addr.to_string());
|
||||
}
|
||||
|
||||
} // std
|
||||
#endif // TINS_IS_CXX11
|
||||
|
||||
Reference in New Issue
Block a user