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()
);
98 #ifndef DOXYGEN_SHOULD_SKIP_THIS
Id hash(const std::string &str)
Get an idenfitier from a string.
Definition: Id.h:74
constexpr Id hash(const char *str, std::size_t sz)
Get an identifier from a string.
Definition: Id.h:62
constexpr gf::Id operator""_id(const char *str, std::size_t sz)
User defined operator for creating compile time ids from strings.
Definition: Id.h:92
constexpr Id InvalidId
The invalid id (which is 0)
Definition: Id.h:44