27 #include "Portability.h" 30 #ifndef DOXYGEN_SHOULD_SKIP_THIS 62 constexpr
Id hash(
const char *str, std::size_t sz) {
63 return sz == 0 ? 0xcbf29ce484222325 : (str[sz - 1] ^
hash(str, sz - 1)) * 0x100000001b3;
74 inline Id hash(
const std::string& str) {
75 return hash(str.c_str(), str.size());
92 constexpr
gf::Id operator"" _id(
const char *str, std::size_t sz) {
98 #ifndef DOXYGEN_SHOULD_SKIP_THIS uint64_t Id
An identifier.
Definition: Id.h:38
constexpr Id hash(const char *str, std::size_t sz)
Get an identifier from a string.
Definition: Id.h:62
The namespace for gf classes.
Definition: Action.h:34
constexpr Id InvalidId
The invalid id (which is 0)
Definition: Id.h:44