diff options
| author | Charles <sircharlesaze@gmail.com> | 2020-06-19 14:38:15 +0200 |
|---|---|---|
| committer | Charles <sircharlesaze@gmail.com> | 2020-06-19 17:53:28 +0200 |
| commit | e085451ec45c0551c80989a7d49b0e0deb4b9586 (patch) | |
| tree | 0ecddd9b145318eaa84c6de2f9c251a6e2a0e195 /src/debug.c | |
| parent | 831cc03ff6c01fb78d77629b7a8f2a75d9e9f75a (diff) | |
| download | minishell-e085451ec45c0551c80989a7d49b0e0deb4b9586.tar.gz minishell-e085451ec45c0551c80989a7d49b0e0deb4b9586.tar.bz2 minishell-e085451ec45c0551c80989a7d49b0e0deb4b9586.zip | |
Parenthesis working, Added getline loop in main
Diffstat (limited to 'src/debug.c')
| -rw-r--r-- | src/debug.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/src/debug.c b/src/debug.c index b23fe51..c2b416e 100644 --- a/src/debug.c +++ b/src/debug.c @@ -34,9 +34,8 @@ void ast_print(int level, t_ast *ast) ft_lstiter(ast->redirs, token_put); printf(" ]\n"); ast_print(level + 1, ast->parent_ast); - } - if (ast->tag == AST_CMD) + else if (ast->tag == AST_CMD) { print_level(level); printf("cmd: [ "); @@ -45,8 +44,7 @@ void ast_print(int level, t_ast *ast) ft_lstiter(ast->redirs, token_put); printf(" ]"); } - else - { + else if (ast->tag == AST_OP) { /* printf("SEP: %d\n", ast->op.sep); */ print_level(level); /* printf("redirs: ["); */ |
