Boot framework rework (#45)
[lunaix-os.git] / lunaix-os / includes / lunaix / ds / hstr.h
index d954103ce44f797024133d41f2189e37c97bc4ca..169f0b8eccb0de6ad0c795cb4ffe02041f660e4c 100644 (file)
@@ -1,14 +1,14 @@
 #ifndef __LUNAIX_HSTR_H
 #define __LUNAIX_HSTR_H
 
-#include <lib/hash.h>
+#include <klibc/hash.h>
 
 #define HSTR_FULL_HASH 32
 
 struct hstr
 {
-    u32_t hash;
-    u32_t len;
+    unsigned int hash;
+    unsigned int len;
     const char* value;
 };
 
@@ -26,6 +26,10 @@ struct hstr
 
 #define HSTR_EQ(str1, str2) ((str1)->hash == (str2)->hash)
 
+#define HSTR_VAL(hstr)  ((hstr).value)
+#define HSTR_LEN(hstr)  ((hstr).len)
+#define HSTR_HASH(hstr) ((hstr).hash)
+
 inline void
 hstr_rehash(struct hstr* hash_str, u32_t truncate_to)
 {