diff --git a/selfhost/cmd/w6c/main.combined.ww b/selfhost/cmd/w6c/main.combined.ww index 7207319a..5cb26325 100644 --- a/selfhost/cmd/w6c/main.combined.ww +++ b/selfhost/cmd/w6c/main.combined.ww @@ -9671,6 +9671,12 @@ export fn checkfile(c: *checker, file: *node) void = { d = file.list; for (d != nil) { c.curmod = declmod(file, d); + // A.6.2.1-pre — attr-subtree gap: top-level dispatch below walks + // d.lhs / d.body per kind but never d.attr, leaving `@symbol("…")` + // arg literals (N_STRLIT) outside the post-order exprtype + // dispatch. Mirror resolvewalk L405 which descends n.attr on + // inner nodes. + if (d.attr != nil) { resolvewalk(c, d.attr); }; let k: nkind = d.kind; if (k == nkind.N_FNDECL) { if (d.lhs != nil) { resolvewalk(c, d.lhs); }; // return type diff --git a/selfhost/cmd/wcc/check.ww b/selfhost/cmd/wcc/check.ww index 00221e72..118cf94d 100644 --- a/selfhost/cmd/wcc/check.ww +++ b/selfhost/cmd/wcc/check.ww @@ -2707,6 +2707,12 @@ export fn checkfile(c: *checker, file: *node) void = { d = file.list; for (d != nil) { c.curmod = declmod(file, d); + // A.6.2.1-pre — attr-subtree gap: top-level dispatch below walks + // d.lhs / d.body per kind but never d.attr, leaving `@symbol("…")` + // arg literals (N_STRLIT) outside the post-order exprtype + // dispatch. Mirror resolvewalk L405 which descends n.attr on + // inner nodes. + if (d.attr != nil) { resolvewalk(c, d.attr); }; let k: nkind = d.kind; if (k == nkind.N_FNDECL) { if (d.lhs != nil) { resolvewalk(c, d.lhs); }; // return type diff --git a/selfhost/cmd/wwdump/main.combined.ww b/selfhost/cmd/wwdump/main.combined.ww index 6eb2071d..0ee89acf 100644 --- a/selfhost/cmd/wwdump/main.combined.ww +++ b/selfhost/cmd/wwdump/main.combined.ww @@ -9671,6 +9671,12 @@ export fn checkfile(c: *checker, file: *node) void = { d = file.list; for (d != nil) { c.curmod = declmod(file, d); + // A.6.2.1-pre — attr-subtree gap: top-level dispatch below walks + // d.lhs / d.body per kind but never d.attr, leaving `@symbol("…")` + // arg literals (N_STRLIT) outside the post-order exprtype + // dispatch. Mirror resolvewalk L405 which descends n.attr on + // inner nodes. + if (d.attr != nil) { resolvewalk(c, d.attr); }; let k: nkind = d.kind; if (k == nkind.N_FNDECL) { if (d.lhs != nil) { resolvewalk(c, d.lhs); }; // return type