gingerBill 11 місяців тому
батько
коміт
3498d4341d
1 змінених файлів з 4 додано та 0 видалено
  1. 4 0
      src/check_decl.cpp

+ 4 - 0
src/check_decl.cpp

@@ -232,6 +232,10 @@ gb_internal bool check_override_as_type_due_to_aliasing(CheckerContext *ctx, Ent
 		// until there is a proper delaying system to try declaration again if they
 		// have failed.
 
+		if (e->type != nullptr && is_type_typed(e->type)) {
+			return false;
+		}
+
 		e->kind = Entity_TypeName;
 		check_type_decl(ctx, e, init, named_type);
 		return true;