C++ refactoring (#91)

This commit is contained in:
Ken Van Hoeylandt
2024-11-26 17:51:05 +01:00
committed by GitHub
parent d06137ba76
commit ca5d4b8226
159 changed files with 904 additions and 1086 deletions
+22
View File
@@ -0,0 +1,22 @@
#pragma once
#include <cstddef>
#include <cstdint>
namespace tt::crypt {
/**
* Implementation of DJB2 hashing algorithm.
* @param[in] str the string to calculate the hash for
* @return the hash
*/
uint32_t djb2(const char* str);
/**
* Implementation of DJB2 hashing algorithm.
* @param[in] data the bytes to calculate the hash for
* @return the hash
*/
uint32_t djb2(const void* data, size_t length);
} // namespace