-
Notifications
You must be signed in to change notification settings - Fork 12.7k
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
rustc_target: Update some old naming around self contained linking #100126
Conversation
r? @lcnr (rust-highfive has picked a reviewer for you, use r? to override) |
|
"mingw" => CrtObjectsFallback::Mingw, | ||
"wasm" => CrtObjectsFallback::Wasm, | ||
"false" => LinkSelfContainedDefault::False, | ||
"true" | "wasm" => LinkSelfContainedDefault::True, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is the wasm case here for back-compat for any out-of-tree target specs?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I doubt that it's used anywhere, but I just kept full backward compatibility for all options for now.
+1 This naming makes the option a lot less confusing. LGTM |
r? compiler |
/// Same as `(pre|post)_link_objects`, but when self-contained linking mode is enabled. | ||
pub pre_link_objects_self_contained: CrtObjects, | ||
pub post_link_objects_self_contained: CrtObjects, | ||
pub link_self_contained_default: LinkSelfContainedDefault, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pub link_self_contained_default: LinkSelfContainedDefault, | |
pub link_self_contained: LinkSelfContainedDefault, |
Large number of target options target.foo
provide defaults for something that can also be user-specified -Cfoo=override
, and almost none of them uses the _default
suffix.
r? compiler |
@bors r+ |
rustc_target: Update some old naming around self contained linking The "fallback" naming pre-dates introduction of `-Clink-self-contained`. Noticed when reviewing rust-lang#99500. This PR doesn't break any json target spec, but supporting per-linker-flavor startup objects needed by rust-lang#99500 will break them, so maybe next time I'll remove the compatibility names.
This comment was marked as resolved.
This comment was marked as resolved.
The "fallback" naming pre-dates introduction of `-Clink-self-contained`
@bors r=davidtwco |
rustc_target: Update some old naming around self contained linking The "fallback" naming pre-dates introduction of `-Clink-self-contained`. Noticed when reviewing rust-lang#99500. This PR doesn't break any json target spec, but supporting per-linker-flavor startup objects needed by rust-lang#99500 will break them, so maybe next time I'll remove the compatibility names.
Rollup of 6 pull requests Successful merges: - rust-lang#99582 (Delay a span bug if we see ty/const generic params during writeback) - rust-lang#99861 (orphan check: rationalize our handling of constants) - rust-lang#100026 (Add `Iterator::array_chunks` (take N+1)) - rust-lang#100115 (Suggest removing `let` if `const let` or `let const` is used) - rust-lang#100126 (rustc_target: Update some old naming around self contained linking) - rust-lang#100487 (`assert_{inhabited,zero_valid,uninit_valid}` intrinsics are safe) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
The "fallback" naming pre-dates introduction of
-Clink-self-contained
.Noticed when reviewing #99500.
This PR doesn't break any json target spec, but supporting per-linker-flavor startup objects needed by #99500 will break them, so maybe next time I'll remove the compatibility names.