dead_code lint not running on code generated by crate-external macros · Issue #53209 · rust-lang/rust (original) (raw)

Skip to content

Provide feedback

Saved searches

Use saved searches to filter your results more quickly

Sign up

Appearance settings

@KodrAus

Description

@KodrAus

We've hit a bit of a snag in rust-lang-nursery/lazy-static.rs#110 where it looks like the dead_code lint for code generated by the lazy_static macro in external crates isn't being triggered and is causing one of our compilefail tests to start building instead of failing.

I'm just trying to track down what we changed here in the compiler to get some context about how we should approach the issue in lazy_static. We can probably live with warnings not being surfaced if there's some bigger picture around the change. I may also be totally off in the weeds on this.

EDIT: The change was somewhere between 12ed235 and 6a1c063