X-Git-Url: https://harrygodden.com/git/?a=blobdiff_plain;f=src%2Fvg%2Fvg_store.h;h=ee0e91acf04d3e94579b1f62c7dfafda8d322a9d;hb=3dd767bb10e6fee9cbffeb185d1a9685810c17b5;hp=075695ecca95181dff3ff854f1fa4e0c2b6d8b02;hpb=04107408ecd2adf031abb286c4c5b7d5cc0c3c9d;p=vg.git diff --git a/src/vg/vg_store.h b/src/vg/vg_store.h index 075695e..ee0e91a 100644 --- a/src/vg/vg_store.h +++ b/src/vg/vg_store.h @@ -3,12 +3,15 @@ #include "vg_stdint.h" #include "vg_io.h" +#include "vg_log.h" /* * Anderson tree implementation with extensions: * parents are kept track of * duplicates are allowed * data is never allocated or destroyed here + * + * TODO: seperate offset,stride,base into 'generic array', seperate pool */ typedef struct aatree aatree; @@ -560,10 +563,10 @@ static void aatree_show_r( aatree *tree, aatree_ptr t, int lvl, for( int i=0; iright, lvl+1, p_show ); } @@ -579,10 +582,10 @@ static void aatree_show( aatree *tree, aatree_ptr t, void(*p_show)(void *data)) for( int i=0; ilevel; i++ ) { - vg_log( " " ); + vg_info( " " ); } p_show( data ); - vg_log( " (%d) \n", t ); + vg_info( " (%d) \n", t ); aatree_show( tree, ptnode->right, p_show ); } @@ -601,7 +604,7 @@ static void aatree_show_counts( aatree *tree, aatree_ptr t, int lvl, int *ln, aatree_show_counts( tree, ptnode->left, lvl+1, ln, err, p_show, show ); - if( show ) vg_log( "%03d| ", *ln ); + if( show ) vg_info( "%03d| ", *ln ); *ln = *ln +1; if( show ) @@ -627,7 +630,7 @@ static void aatree_show_counts( aatree *tree, aatree_ptr t, int lvl, int *ln, if( !aatree_verify( tree, t ) ) { if( show ) - vg_log( "error\n" ); + vg_info( "error\n" ); *err = 1; }