ston testing
[henge/apc.git] / src / testston.c
diff --git a/src/testston.c b/src/testston.c
new file mode 100644 (file)
index 0000000..71c0110
--- /dev/null
@@ -0,0 +1,16 @@
+#include "../ston/ston.h"
+#include <stdlib.h> //malloc
+#include <stdio.h> //print
+
+int main(int argc, char* argv[])
+{ ston_ht ht;
+  uint32_t* htval;
+
+  if ((ht = ston_ht32_new(2,1,0,malloc)) == NULL)
+    fprintf(stderr,"Could not allocate ht32\n");
+  ston_ht32_insertx(ht,50,1,200);
+  htval = ston_ht32_entry(ht,50,1);
+  printf("[50][1] = %i\n",*htval);
+  free(ht);
+  return 0;
+}