Skip to content

Investigate and implement a scheme to consistently apply lints for all compiler crates #138106

Description

@jieyouxu

... Especially for build scripts or proc-macro crates.

There's caveats like:

  • RUSTFLAGS is only applied to target crates, not to host crates.
  • cargo's current [lints] only supports "regular" lints not tool lints like rustc::xxx.

One possible scheme may be to...

[..] unconditionally passing an arbitrary flag and asserting its presence in each compiler crate. Ugly, but it could work I think.
#138035 (comment)

Discussion: https://rust-lang.zulipchat.com/#narrow/channel/326414-t-infra.2Fbootstrap/topic/Consistent.20handling.20of.20compiler.2F*.20RUSTFLAGs.20and.20lints

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-cleanupCategory: PRs that clean code up or issues documenting cleanup.E-needs-designThis issue needs exploration and design to see how and if we can fix/implement itT-bootstrapRelevant to the bootstrap subteam: Rust's build system (x.py and src/bootstrap)

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions