nngn
Loading...
Searching...
No Matches
hash.h
Go to the documentation of this file.
1
#ifndef NNGN_MATH_HASH_H
2
#define NNGN_MATH_HASH_H
3
4
#include <span>
5
#include <string_view>
6
7
namespace
nngn
{
8
9
using
Hash
= std::size_t;
10
11
// TODO constexpr
12
inline
Hash
hash
(std::span<const char>
s
)
13
{
return
std::hash<std::string_view>{}({
s
.data(),
s
.size()}); }
14
15
}
16
17
#endif
nngn
Definition:
debug.h:45
nngn::Hash
std::size_t Hash
Definition:
hash.h:9
nngn::hash
Hash hash(std::span< const char > s)
Definition:
hash.h:12
s
std::chrono::seconds s
Definition:
timing.cpp:6
src
math
hash.h
Generated by
1.9.6