From dd6159479454cfea872c86b132b29e21f1bc894b Mon Sep 17 00:00:00 2001 From: Krzosa Karol Date: Fri, 31 Mar 2023 21:43:44 +0200 Subject: [PATCH] Add core printer file --- core_polymorph.cpp | 4 ++++ core_printer.cpp | 0 2 files changed, 4 insertions(+) create mode 100644 core_printer.cpp diff --git a/core_polymorph.cpp b/core_polymorph.cpp index 26b4db8..89ac67b 100644 --- a/core_polymorph.cpp +++ b/core_polymorph.cpp @@ -204,6 +204,8 @@ void next(Ast_Iter *iter) { For(node->ret) iter->stack.add(it); For(node->args) iter->stack.add(it); } break; + + default: assert(!"Invalid default case"); } end_of_switch: @@ -479,6 +481,8 @@ Ast *ast_copy(Ast *ast, Ast_Scope *parent_scope) { dst->scope = (Ast_Scope *)ast_copy(src->scope, parent_scope); return dst; } break; + + default: assert(!"Invalid default case"); } invalid_return; } \ No newline at end of file diff --git a/core_printer.cpp b/core_printer.cpp new file mode 100644 index 0000000..e69de29