Skip to content

Commit b1a9f9e

Browse files
committed
visit the paths in pre-expansion macros
1 parent 38774aa commit b1a9f9e

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

src/librustc/lint/context.rs

+7
Original file line numberDiff line numberDiff line change
@@ -1117,6 +1117,13 @@ impl<'a> ast_visit::Visitor<'a> for EarlyContext<'a> {
11171117
}
11181118

11191119
fn visit_mac(&mut self, mac: &'a ast::Mac) {
1120+
// FIXME(#54110): So, this setup isn't really right. I think
1121+
// that (a) the libsyntax visitor ought to be doing this as
1122+
// part of `walk_mac`, and (b) we should be calling
1123+
// `visit_path`, *but* that would require a `NodeId`, and I
1124+
// want to get #53686 fixed quickly. -nmatsakis
1125+
ast_visit::walk_path(self, &mac.node.path);
1126+
11201127
run_lints!(self, check_mac, mac);
11211128
}
11221129
}

0 commit comments

Comments
 (0)