Skip to content

Tracking Issue for rustc --check-cfg integration #10554

Closed
@weihanglo

Description

Summary

RFC: #3013
rustc tracking issue: rust-lang/rust#82450

Documentation:

This tracks the integration of rustc --check-cfg flag (RFC #3013), which enables complete or partial checking of conditional compilation configuration at compile time.

Unresolved Issues

  • Should these flags be enabled by default? What's the unintrusive interface to provide for users to opt-out the checking?
  • If we feel the diagnostic on using a feature when no features are defined is insufficient, then do we feel it would not be incongruous with the design to fix this in the future? (see Fix --check-cfg invocations with zero features #13011).

Post-RFC decisions

  • Support cargo:rustc-check-cfg despite :: being introduced in 1.77 and this being released after that. This was done to allow for wider MSRVs while using this feature

Future Extensions

No response

About tracking issues

Tracking issues are used to record the overall progress of implementation.
They are also used as hubs connecting to other relevant issues, e.g., bugs or open design questions.
A tracking issue is however not meant for large scale discussion, questions, or bug reports about a feature.
Instead, open a dedicated issue for the specific matter and add the relevant feature gate label.

Implementation history:

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-tracking-issueCategory: A tracking issue for something unstable.S-needs-mentorStatus: Issue or feature is accepted, but needs a team member to commit to helping and reviewing.S-waiting-on-feedbackStatus: An implemented feature is waiting on community feedback for bugs or design concerns.T-cargoTeam: Cargodisposition-mergeFCP with intent to mergefinished-final-comment-periodFCP complete

    Type

    No type

    Projects

    • Status

      Unstable, baking
    • Status

      FCP merge

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions