diff options
author | Teddy <[email protected]> | 2014-03-24 23:24:59 +0800 |
---|---|---|
committer | Teddy <[email protected]> | 2014-03-24 23:24:59 +0800 |
commit | 6172cc802ea408e9050ec6e3b3f5b6959b07c87d (patch) | |
tree | 49310b585d19e8b406c15c4f39af9682dd80ae26 /ast.h | |
parent | 34c3611f364b3ea2955cbfac934b17900390364d (diff) |
fancy AST output
Diffstat (limited to 'ast.h')
-rw-r--r-- | ast.h | 5 |
1 files changed, 4 insertions, 1 deletions
@@ -20,6 +20,8 @@ #define STMT_BREAK 1040 #define STMT_RET 1041 +#define MAX_CHDN 1024 + typedef struct CNode { enum { /* Top Level */ @@ -67,6 +69,7 @@ typedef struct CNode { } CNode; void cnode_init(); +CNode *cnode_create_ast(CNode *wrapped); CNode *cnode_create_nop(); CNode *cnode_create_general(int type, int subtype, int pnum, va_list ap); CNode *cnode_list_append(CNode *list, CNode *tail); @@ -89,7 +92,7 @@ CNode *cnode_create_int_const(int val); CNode *cnode_create_char_const(int val); CNode *cnode_create_str_const(char *val); -void cnode_debug_print(CNode *ast); +void cnode_debug_print(CNode *ast, int fancy); extern CNode *ast_root; extern CNode *null; |