-
Notifications
You must be signed in to change notification settings - Fork 13.3k
Move sys::pal::os::Env
into sys::env
#140143
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
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Although `Env` (as `Vars`), `Args`, path functions, and OS constants are publicly exposed via `std::env`, their implementations are each self-contained. Keep them separate in `std::sys` and make a new module, `sys::env`, for `Env`.
These have grown out of sync with the platforms.
24 tasks
Also, update the same pattern of reuse in `sys::args` to match.
Thank you! |
Zalathar
added a commit
to Zalathar/rust
that referenced
this pull request
Apr 24, 2025
Move `sys::pal::os::Env` into `sys::env` Although `Env` (as `Vars`), `Args`, path functions, and OS constants are publicly exposed via `std::env`, their implementations are each self-contained. Keep them separate in `std::sys` and make a new module, `sys::env`, for `Env`. Also fix `unsafe_op_in_unsafe_fn` for Unix and update the `!DynSend` and `!DynSync` impls which had grown out of sync with the platforms (see rust-lang#48005 for discussion on that). r? joboet Tracked in rust-lang#117276.
bors
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Apr 24, 2025
Rollup of 23 pull requests Successful merges: - rust-lang#139261 (mitigate MSVC alignment issue on x86-32) - rust-lang#139307 (std: Add performance warnings to HashMap::get_disjoint_mut) - rust-lang#139700 (Autodiff flags) - rust-lang#139752 (set subsections_via_symbols for ld64 helper sections) - rust-lang#139809 (Don't warn about `v128` in wasm ABI transition) - rust-lang#139852 (StableMIR: Implement `CompilerInterface`) - rust-lang#139945 (Extend HIR to track the source and syntax of a lifetime) - rust-lang#140028 (`deref_patterns`: support string and byte string literals in explicit `deref!("...")` patterns) - rust-lang#140139 (rustc_target: Adjust RISC-V feature implication) - rust-lang#140143 (Move `sys::pal::os::Env` into `sys::env`) - rust-lang#140148 (CI: use aws codebuild for job dist-arm-linux) - rust-lang#140150 (fix MAX_EXP and MIN_EXP docs) - rust-lang#140172 (Make algebraic functions into `const fn` items.) - rust-lang#140177 ([compiletest] Parallelize test discovery) - rust-lang#140181 (Remove `synstructure::Structure::underscore_const` calls.) - rust-lang#140184 (Update doc of cygwin target) - rust-lang#140186 (Rename `compute_x` methods) - rust-lang#140187 ([AIX] Handle AIX dynamic library extensions within c-link-to-rust-dylib run-make test) - rust-lang#140191 (Remove git repository from git config) - rust-lang#140194 (minicore: Have `//@ add-core-stubs` also imply `-Cforce-unwind-tables=yes`) - rust-lang#140195 (triagebot: label minicore changes w/ `A-test-infra-minicore` and ping jieyouxu on changes) - rust-lang#140202 (Make #![feature(let_chains)] bootstrap conditional in compiler/) - rust-lang#140214 (Remove comment about handling non-global where bounds with corresponding projection) r? `@ghost` `@rustbot` modify labels: rollup
bors
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Apr 25, 2025
…iaskrgr Rollup of 8 pull requests Successful merges: - rust-lang#137653 (Deprecate the unstable `concat_idents!`) - rust-lang#138957 (Update the index of Option to make the summary more comprehensive) - rust-lang#140006 (ensure compiler existance of tools on the dist step) - rust-lang#140143 (Move `sys::pal::os::Env` into `sys::env`) - rust-lang#140202 (Make #![feature(let_chains)] bootstrap conditional in compiler/) - rust-lang#140236 (norm nested aliases before evaluating the parent goal) - rust-lang#140257 (Some drive-by housecleaning in `rustc_borrowck`) - rust-lang#140278 (Don't use item name to look up associated item from trait item) r? `@ghost` `@rustbot` modify labels: rollup
rust-timer
added a commit
to rust-lang-ci/rust
that referenced
this pull request
Apr 25, 2025
Rollup merge of rust-lang#140143 - thaliaarchi:move-env-pal, r=joboet Move `sys::pal::os::Env` into `sys::env` Although `Env` (as `Vars`), `Args`, path functions, and OS constants are publicly exposed via `std::env`, their implementations are each self-contained. Keep them separate in `std::sys` and make a new module, `sys::env`, for `Env`. Also fix `unsafe_op_in_unsafe_fn` for Unix and update the `!DynSend` and `!DynSync` impls which had grown out of sync with the platforms (see rust-lang#48005 for discussion on that). r? joboet Tracked in rust-lang#117276.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
O-hermit
Operating System: Hermit
O-SGX
Target: SGX
O-solid
Operating System: SOLID
O-unix
Operating system: Unix-like
O-wasi
Operating system: Wasi, Webassembly System Interface
O-windows
Operating system: Windows
S-waiting-on-bors
Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
T-compiler
Relevant to the compiler team, which will review and decide on the PR/issue.
T-libs
Relevant to the library team, which will review and decide on the PR/issue.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Although
Env
(asVars
),Args
, path functions, and OS constants are publicly exposed viastd::env
, their implementations are each self-contained. Keep them separate instd::sys
and make a new module,sys::env
, forEnv
.Also fix
unsafe_op_in_unsafe_fn
for Unix and update the!DynSend
and!DynSync
impls which had grown out of sync with the platforms (see #48005 for discussion on that).r? joboet
Tracked in #117276.