mirror of
https://github.com/odin-lang/Odin.git
synced 2026-01-02 11:12:31 +00:00
Compound literals and Warnings
This commit is contained in:
@@ -18,6 +18,20 @@ void print_ast(AstNode *node, isize indent) {
|
||||
print_indent(indent);
|
||||
print_token(node->identifier.token);
|
||||
break;
|
||||
case AstNode_ProcedureLiteral:
|
||||
print_indent(indent);
|
||||
gb_printf("(proc lit)\n");
|
||||
print_ast(node->procedure_literal.type, indent+1);
|
||||
print_ast(node->procedure_literal.body, indent+1);
|
||||
break;
|
||||
|
||||
case AstNode_CompoundLiteral:
|
||||
print_indent(indent);
|
||||
gb_printf("(compound lit)\n");
|
||||
print_ast(node->compound_literal.type_expression, indent+1);
|
||||
print_ast(node->compound_literal.element_list, indent+1);
|
||||
break;
|
||||
|
||||
|
||||
case AstNode_TagExpression:
|
||||
print_indent(indent);
|
||||
|
||||
Reference in New Issue
Block a user