diff --git a/src/sfizz/utility/NumericId.h b/src/sfizz/utility/NumericId.h index 5abd906f..73d0b12f 100644 --- a/src/sfizz/utility/NumericId.h +++ b/src/sfizz/utility/NumericId.h @@ -5,6 +5,8 @@ // If not, contact the sfizz maintainers at https://github.com/sfztools/sfizz #pragma once +#include "../StringViewHelpers.h" +#include /** * @brief Numeric identifier @@ -50,3 +52,12 @@ struct NumericId { private: int number_ = -1; }; + +namespace std { + template struct hash> { + size_t operator()(const NumericId &id) const + { + return hashNumber(id.number()); + } + }; +}