aboutsummaryrefslogtreecommitdiff
path: root/advent-of-code/2022/lib/htable.h
diff options
context:
space:
mode:
authorMistivia <i@mistivia.com>2024-02-16 11:11:14 +0800
committerMistivia <i@mistivia.com>2024-02-16 11:11:14 +0800
commit050fa7cbfb6b7cf293fb02e06daf123b3e6af816 (patch)
treeb547869fabbbf1f1153098ef811398ed40485d0a /advent-of-code/2022/lib/htable.h
parente1a5304af2c35ff83819546953309764e24656d4 (diff)
delete advent of code 2022
Diffstat (limited to 'advent-of-code/2022/lib/htable.h')
-rw-r--r--advent-of-code/2022/lib/htable.h29
1 files changed, 0 insertions, 29 deletions
diff --git a/advent-of-code/2022/lib/htable.h b/advent-of-code/2022/lib/htable.h
deleted file mode 100644
index 3bde74f..0000000
--- a/advent-of-code/2022/lib/htable.h
+++ /dev/null
@@ -1,29 +0,0 @@
-#ifndef HTABLE_H_
-#define HTABLE_H_
-
-#include <stdbool.h>
-#include <stdint.h>
-
-typedef struct {
- void *buf;
- int size;
- int cap;
- int taken;
- void* begin;
- int elemsz;
- uint32_t (*hash)(void*);
- bool (*eq)(void*, void*);
-} HTable;
-
-void htable_init(HTable *ht, int elemsz, int cap, uint32_t (*hash)(void*),
- bool (*eq)(void*, void*));
-bool htable_insert(HTable *ht, void* elem);
-void htable_del(HTable *ht, void* iter);
-
-// return a iterator
-void* htable_find(HTable *ht, void* elem);
-void* htable_begin(HTable *ht);
-void* htable_next(HTable *ht, void *iter);
-
-#endif
-