diff options
author | Stefan Zabka <zabkaste@hu-berlin.de> | 2020-06-22 16:43:42 +0200 |
---|---|---|
committer | Stefan Zabka <zabkaste@hu-berlin.de> | 2020-06-22 16:43:42 +0200 |
commit | 239f248456ad00f894dc26dceefa968898738c9d (patch) | |
tree | 14d41af555b12c88401d8bb46bae9f4319497b62 /04_exercise/slotmap/slomap_test.c | |
parent | 021afcb8e4aa4fbc7905f527089c415108c86c75 (diff) | |
download | betriebssysteme-239f248456ad00f894dc26dceefa968898738c9d.tar.gz betriebssysteme-239f248456ad00f894dc26dceefa968898738c9d.zip |
Getting make to run
Diffstat (limited to '04_exercise/slotmap/slomap_test.c')
-rw-r--r-- | 04_exercise/slotmap/slomap_test.c | 19 |
1 files changed, 0 insertions, 19 deletions
diff --git a/04_exercise/slotmap/slomap_test.c b/04_exercise/slotmap/slomap_test.c deleted file mode 100644 index 930bfa8..0000000 --- a/04_exercise/slotmap/slomap_test.c +++ /dev/null @@ -1,19 +0,0 @@ -// -// Created by stefan on 18.06.20. -// -#include <assert.h> -#include <slotmap.h> -#include <stdbool.h> - -bool find1(void const * ptr) { - return * (int const *) ptr == 1; -} -int main() { - smEntry slab [10]; - int data [6] = {0, 1, 2,3,4,5}; - smHeader header = smInit((smEntry *)&slab, 10); - smInsert(&header, &data[1]); - smEntry * entry = smFindEntry(&header, &find1); - assert(*(int *)entry->value == 1); - return 0; -} |