File tree Expand file tree Collapse file tree 3 files changed +5
-8
lines changed
Expand file tree Collapse file tree 3 files changed +5
-8
lines changed Original file line number Diff line number Diff line change @@ -93,9 +93,9 @@ static const char *exprString[] = {
9393//" |--
9494static uint64_t printSpace = 0 ;
9595
96- static void print_space (){
97- for (uint64_t i = 0 ;i < printSpace ;i ++ )
98- printf ("%c " , i %5 == 0 ? '|' : ' ' );
96+ void expr_print_space ( uint64_t sp ){
97+ for (uint64_t i = 0 ;i < sp ;i ++ )
98+ printf ("%s " , i %5 == 0 ? "|" : " " );
9999}
100100
101101static void expr_print2 (Expression * expr ){
Original file line number Diff line number Diff line change @@ -69,4 +69,6 @@ Expression* expr_new(ExpressionType type);
6969void expr_dispose ();
7070#ifdef DEBUG
7171void expr_print (Expression * exp , uint64_t printSpace );
72+ void expr_print_space (uint64_t space );
73+ #define print_space () expr_print_space(printSpace)
7274#endif
Original file line number Diff line number Diff line change @@ -132,11 +132,6 @@ static const char *stmtString[] = {
132132//" |--
133133static uint64_t printSpace = 0 ;
134134
135- static void print_space (){
136- for (uint64_t i = 0 ;i < printSpace ;i ++ )
137- printf ("%c" , i %5 == 0 ?'|' :' ' );
138- }
139-
140135static void stmt_print2 (Statement * stmt ){
141136 printf ("\n" );
142137 uint64_t bak = printSpace ;
You can’t perform that action at this time.
0 commit comments