]> Nishi Git Mirror - gwion.git/commitdiff
:bug: disallow unresolved partials
authorfennecdjay <fennecdjay@gmail.com>
Tue, 20 Dec 2022 11:15:22 +0000 (12:15 +0100)
committerfennecdjay <fennecdjay@gmail.com>
Tue, 20 Dec 2022 11:15:22 +0000 (12:15 +0100)
src/emit/emit.c

index 0323907928772288a62477cc97d760b7be8afa63..7838adcd38933c36c2003fb824fad930d170c5e8 100644 (file)
@@ -1120,6 +1120,8 @@ ANN static m_bool emit_decl(const Emitter emit, Exp_Decl *const decl) {
 
 ANN /*static */ m_bool emit_exp_decl(const Emitter emit, Exp_Decl *const decl) {
   const Type t = decl->type;
+  if(decl->args && !strncmp(decl->args->type->name, "partial:", 8))
+    ERR_B(decl->args->pos, "unresolved partial");
   CHECK_BB(ensure_emit(emit, t));
   const m_bool global = GET_FLAG(decl->td, global);
   const m_uint scope =