SIGN IN SIGN UP
rust-lang / rust UNCLAIMED

Empowering everyone to build reliable and efficient software.

0 0 0 Rust

Auto merge of #150310 - JonathanBrouwer:cfg_trace2, r=jdonszelmann

Port `#[cfg]` and `#[cfg_attr]` trace attributes to the new attribute parsers

This PR converts `cfg` and `cfg_trace` attributes to the new parsed representation.

The primary challenge is that re-parsing these attributes in the HIR is a performance regression, since these attributes were only used in rustdoc and clippy parsing them in the HIR is extra work that was not done in the compiler before. To solve this, we only parse the attributes once and then store their parsed representation in the AST.
B
bors committed
d9617c8d9a55773a96b61ba3a4acb107d65615c1