Sema: queue full type resolution of builtin types

This commit is contained in:
Andrew Kelley 2022-03-28 18:49:49 -07:00
parent 4dd65316b7
commit 8df84cce8b

View File

@ -11594,6 +11594,7 @@ fn typeInfoDecls(
var buffer: Value.ToTypeBuffer = undefined;
break :t try declaration_ty_decl.val.toType(&buffer).copy(decls_anon_decl.arena());
};
try sema.queueFullTypeResolution(try declaration_ty.copy(sema.arena));
const decls_len = if (opt_namespace) |ns| ns.decls.count() else 0;
const decls_vals = try decls_anon_decl.arena().alloc(Value, decls_len);
@ -22047,7 +22048,9 @@ fn getBuiltinType(
name: []const u8,
) CompileError!Type {
const ty_inst = try sema.getBuiltin(block, src, name);
return sema.analyzeAsType(block, src, ty_inst);
const result_ty = try sema.analyzeAsType(block, src, ty_inst);
try sema.queueFullTypeResolution(result_ty);
return result_ty;
}
/// There is another implementation of this in `Type.onePossibleValue`. This one