aboutsummaryrefslogtreecommitdiff
path: root/strbst.h
diff options
context:
space:
mode:
authorHolden Rohrer <hr@hrhr.dev>2020-05-27 16:21:02 -0400
committerHolden Rohrer <hr@hrhr.dev>2020-05-27 16:21:24 -0400
commit290f2b95ee100735f55fe10af457cc65158af043 (patch)
tree6f72fa5c6312460c04cc78dcd71f370097c3903e /strbst.h
parent37cd5bb9e3742f4893a14e04d49a4ba9716455c8 (diff)
Initial working commit
There are still some errors when run through valgrind, but it performs as expected for the test file.
Diffstat (limited to 'strbst.h')
-rw-r--r--strbst.h8
1 files changed, 3 insertions, 5 deletions
diff --git a/strbst.h b/strbst.h
index a58b8d3..7dbbae1 100644
--- a/strbst.h
+++ b/strbst.h
@@ -3,17 +3,15 @@
typedef struct strbstnode {
char* ind;
- void* data;
+ void* data; // as used, always link*
struct strbstnode* left;
struct strbstnode* right;
int ht;
} strbstnode;
-struct strbst {
+typedef struct strbst {
strbstnode* head;
-};
-
-typedef struct strbst strbst;
+} strbst;
strbst* newbst(void);