frontend: add coloured output for try-catch-finally AST nodes
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
#include <blue/term.h>
|
||||
#include <blue/object/string.h>
|
||||
#include <blue/term.h>
|
||||
#include <ivy/asm/lex.h>
|
||||
#include <ivy/lang/ast.h>
|
||||
#include <ivy/lang/lex.h>
|
||||
@@ -147,6 +147,7 @@ extern enum ivy_status print_ast_node(
|
||||
case IVY_AST_COND_GROUP:
|
||||
case IVY_AST_WHILE_LOOP:
|
||||
case IVY_AST_FOR_LOOP:
|
||||
case IVY_AST_TRY:
|
||||
case IVY_AST_RETURN:
|
||||
b_puts("[magenta]");
|
||||
break;
|
||||
@@ -159,10 +160,12 @@ extern enum ivy_status print_ast_node(
|
||||
case IVY_AST_INT:
|
||||
case IVY_AST_DOUBLE:
|
||||
case IVY_AST_ATOM:
|
||||
case IVY_AST_TUPLE:
|
||||
b_puts("[yellow]");
|
||||
break;
|
||||
case IVY_AST_COND:
|
||||
case IVY_AST_BLOCK:
|
||||
case IVY_AST_TRY_CATCH:
|
||||
b_puts("[red]");
|
||||
break;
|
||||
case IVY_AST_IDENT:
|
||||
|
||||
Reference in New Issue
Block a user