From: fennecdjay Date: Wed, 9 Oct 2019 15:13:12 +0000 (+0200) Subject: :art: Clean X-Git-Tag: nightly~2198^2~81 X-Git-Url: http://10.10.0.4:5575/?a=commitdiff_plain;h=800c71f4b7fff32e51f4a621d424068d7f082555;p=gwion.git :art: Clean --- diff --git a/src/emit/emit.c b/src/emit/emit.c index 6d37b6b7..eceb2877 100644 --- a/src/emit/emit.c +++ b/src/emit/emit.c @@ -1361,9 +1361,7 @@ ANN static m_bool emit_stmt_jump(const Emitter emit, const Stmt_Jump stmt) { } ANN static m_bool emit_type_def(const Emitter emit, const Type_Def tdef) { - if(SAFE_FLAG(tdef->type->e->def, emit)) - return GW_OK; - return tdef->type->e->def ? emit_class_def(emit, tdef->type->e->def) : 1; + return tdef->type->e->def ? emit_class_def(emit, tdef->type->e->def) : GW_OK; } ANN static m_bool emit_enum_def(const Emitter emit, const Enum_Def edef) { diff --git a/src/parse/template.c b/src/parse/template.c index 8d79762a..3a60b285 100644 --- a/src/parse/template.c +++ b/src/parse/template.c @@ -16,11 +16,6 @@ #include "cpy_ast.h" #include "tuple.h" -ANN static inline Type owner_type(const Env env, const Type t) { - const Nspc nspc = t->nspc ? t->nspc->parent : NULL; - return (nspc && nspc->parent) ? nspc_lookup_type1(nspc->parent, insert_symbol(nspc->name)) : NULL; -} - struct tmpl_info { const Class_Def cdef; Type_List call;