Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Unify rustc and rustdoc parsing of cfg() #84442

Merged
merged 1 commit into from
May 7, 2021
Merged

Commits on May 3, 2021

  1. Unify rustc and rustdoc parsing of cfg()

    This extracts a new `parse_cfg` function that's used between both.
    
    - Treat `#[doc(cfg(x), cfg(y))]` the same as `#[doc(cfg(x)]
      #[doc(cfg(y))]`. Previously it would be completely ignored.
    - Treat `#[doc(inline, cfg(x))]` the same as `#[doc(inline)]
      #[doc(cfg(x))]`. Previously, the cfg would be ignored.
    - Pass the cfg predicate through to rustc_expand to be validated
    
    Co-authored-by: Vadim Petrochenkov <vadim.petrochenkov@gmail.com>
    jyn514 and petrochenkov committed May 3, 2021
    Configuration menu
    Copy the full SHA
    6eb4735 View commit details
    Browse the repository at this point in the history