29#ifndef DOXYGEN_SHOULD_SKIP_THIS
61 constexpr Id hash(
const char *str, std::size_t sz) {
62 Id value = UINT64_C(0xcbf29ce484222325);
64 for (std::size_t i = 0; i < sz; ++i) {
65 value ^=
static_cast<unsigned char>(str[i]);
66 value *= UINT64_C(0x100000001b3);
83 constexpr Id hash(std::string_view str) {
84 return hash(str.data(), str.size());
102 constexpr gf::Id operator"" _id(
const char *str, std::size_t sz) {
108#ifndef DOXYGEN_SHOULD_SKIP_THIS
uint64_t Id
An identifier.
Definition: Id.h:37
constexpr Id InvalidId
The invalid id (which is 0)
Definition: Id.h:43
constexpr Id hash(const char *str, std::size_t sz)
Get an identifier from a string.
Definition: Id.h:61
The namespace for gf classes.