authorgravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2022-03-28 18:49:49-07:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2022-03-28 18:49:49-07:00
log8df84cce8b68339c332d30213efe90cdc833d059
tree3941d1a7d5cedb2f2223ae22af217b47b40e6fc6
parent4dd65316b7d5756809394710078718b3ee536a9b

Sema: queue full type resolution of builtin types


1 files changed, 4 insertions(+), 1 deletions(-)

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