begenning the refactor

This commit is contained in:
2024-03-27 23:03:54 +01:00
parent e5ff232065
commit 6bbf1e196d
131 changed files with 2135 additions and 1192 deletions

29
runtime/Includes/Utils/CombineHash.h git.filemode.normal_file
View File

@@ -0,0 +1,29 @@
/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* CombineHash.h :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: maldavid <kbz_8.dev@akel-engine.com> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2023/12/14 16:16:06 by maldavid #+# #+# */
/* Updated: 2024/03/27 21:59:30 by maldavid ### ########.fr */
/* */
/* ************************************************************************** */
#ifndef __MLX_HASH__
#define __MLX_HASH__
namespace mlx
{
inline void HashCombine([[maybe_unused]] std::size_t& seed) noexcept {}
template <typename T, typename... Rest>
inline void HashCombine(std::size_t& seed, const T& v, Rest... rest)
{
std::hash<T> hasher;
seed ^= hasher(v) + 0x9e3779b9 + (seed << 6) + (seed >> 2);
HashCombine(seed, rest...);
}
}
#endif