# HG changeset patch # User masa # Date 1449046892 -32400 # Node ID a436526756b9925baf4478e81ce8b7cd4e90cf76 # Parent 7925e9abb0782f75d3582c0a75597ef329a9f380 fix printTree diff -r 7925e9abb078 -r a436526756b9 c/regexParser/node.cc --- a/c/regexParser/node.cc Wed Dec 02 17:51:02 2015 +0900 +++ b/c/regexParser/node.cc Wed Dec 02 18:01:32 2015 +0900 @@ -10,7 +10,11 @@ if (n->tokenType != 'a') { printf("%*c%c(%lu)\n",d*4, ' ',n->tokenType,n->nodeNumber); } else { - printf("%*c%s(%lu)\n",d*4, ' ',n->cc->cond->w->word,n->nodeNumber); + printf("%*c",d*4, ' '); + for (int i = 0; i < n->cc->cond->w->length; i++) { + putchar(n->cc->cond->w->word[i]); + } + printf("(%lu)\n",n->nodeNumber); } if (n->left != NULL) {