-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
Rename environment variable for overriding rustc version #92825
Conversation
(rust-highfive has picked a reviewer for you, use r? to override) |
This will need an update to rustc-perf prior to landing which sets both the old and new env variable to avoid another period of noise. |
This is ready, @matthewjasper—unless there's more to do on the rustc-perf side, first. |
I want to take a closer look before moving ahead with this, but should be able to get to that shortly. It doesn't seem particularly urgent either, I suppose. |
So, I think this is okay, but I would like to see this patch expanded -- right now, there's a bunch of different places CFG_VERSION is read in the compiler, and instead I think we can add a single place that reads it -- probably in rustc_session (maybe rustc_data_structures; play it by ear as the root of the relevant crate tree). That place would do the dispatch on the environment variable querying the version, and be used across all of the places we might read from it -- ideally, that makes the environment variable much more useful, since it's a blanket override to the rustc hash, rather than a partial solution. I think that should be a relatively lightweight set of changes; can you make them in this PR? |
rustc_span doesn't depend on rustc_session.
I think rustc_metadata shouldn't allow overriding the rustc version. Unlike the use in rustc_span it doesn't affect performance in any way. It just changes a couple of bytes at the start of the .rmeta files. |
Ah, yeah, span is going to be a problem... I guess it's true that not all of those places are in need of this override (or really benefit). Let's temporarily leave it then and we can reconsider if we need to change it again. @bors r+ |
📌 Commit 68515cb has been approved by |
…askrgr Rollup of 10 pull requests Successful merges: - rust-lang#90498 (Clarifications in the target tier policy) - rust-lang#92164 (Implement `#[rustc_must_implement_one_of]` attribute) - rust-lang#92729 (rustc_codegen_llvm: Remove (almost) unused span parameter from many functions in metadata.rs) - rust-lang#92752 (Correct minor typos in some long error code explanations) - rust-lang#92801 (Enable wrapping words by default) - rust-lang#92825 (Rename environment variable for overriding rustc version) - rust-lang#92877 (Remove LLVMRustMarkAllFunctionsNounwind) - rust-lang#92936 (rustdoc: Remove `collect` in `html::markdown::parse`) - rust-lang#92956 (Add `log2` and `log10` to `NonZeroU*`) - rust-lang#92960 (Use `carrying_{mul|add}` in `num::bignum`) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
No description provided.