From 95a16d2d88c8628ab0ae76f3ae04dfebee566950 Mon Sep 17 00:00:00 2001 From: Charles Cabergs Date: Thu, 27 Aug 2020 19:13:28 +0200 Subject: Fising tok_lst_new uninitialized next, Added tok_lst_debug, Fixing parse_cmd --- src/debug.c | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) (limited to 'src/debug.c') diff --git a/src/debug.c b/src/debug.c index 8255016..8759252 100644 --- a/src/debug.c +++ b/src/debug.c @@ -1,7 +1,15 @@ #include #include "lexer.h" -#include "ast.h" + +void tok_lst_debug(t_tok_lst *tokens) +{ + while (tokens != NULL) + { + printf("[%#06x] |%s|%s\n", tokens->tag, tokens->content, tokens->tag & TAG_STICK ? " STICK" : ""); + tokens = tokens->next; + } +} /* void token_debug(void *v) */ /* { */ -- cgit