aboutsummaryrefslogtreecommitdiff
path: root/src/Sema.zig
diff options
context:
space:
mode:
authorVeikka Tuominen <git@vexu.eu>2023-01-15 14:06:59 +0200
committerVeikka Tuominen <git@vexu.eu>2023-01-17 20:28:43 +0200
commit6b037bad590bd6c319af336b6d3017c33d6834ba (patch)
tree86557878d6d467a6836c6dd1c74028c6f3b21120 /src/Sema.zig
parent94be9dcc7f2ff81c3433cd2f8bb32f7ea53ba7cf (diff)
downloadzig-6b037bad590bd6c319af336b6d3017c33d6834ba.tar.gz
zig-6b037bad590bd6c319af336b6d3017c33d6834ba.zip
Sema: ignore dependency loops in typeinfo decls
This matches stage1 behavior. Closes #14322
Diffstat (limited to 'src/Sema.zig')
-rw-r--r--src/Sema.zig1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/Sema.zig b/src/Sema.zig
index fcf25ab9bf..4e479d263a 100644
--- a/src/Sema.zig
+++ b/src/Sema.zig
@@ -16258,6 +16258,7 @@ fn typeInfoNamespaceDecls(
for (decls) |decl_index| {
const decl = sema.mod.declPtr(decl_index);
if (decl.kind == .@"usingnamespace") {
+ if (decl.analysis == .in_progress) continue;
try sema.mod.ensureDeclAnalyzed(decl_index);
var buf: Value.ToTypeBuffer = undefined;
const new_ns = decl.val.toType(&buf).getNamespace().?;