-
Notifications
You must be signed in to change notification settings - Fork 12.9k
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
std: Stabilize the env
module
#22869
Conversation
r? @aturon |
(rust_highfive has picked a reviewer for you, use r? to override) |
edb40ce
to
33c9e5d
Compare
pub fn set_exit_status(code: i32) { | ||
EXIT_STATUS.store(code as isize, Ordering::SeqCst) | ||
} | ||
|
||
/// Fetches the process's current exit code. This defaults to 0 and can change | ||
/// by calling `set_exit_status`. | ||
#[unstable(feature = "env", reason = "managing the exit status may change")] |
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.
Hm, you can have both stable
and unstable
items for the same feature name?
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.
Hm right that does sound like a bad idea, I will move these to a new feature name.
33c9e5d
to
974011f
Compare
@bors: r+ 974011f another one bites the dust |
🙀 |
@bors: r+ 974011f |
🙀 |
@alexcrichton Hm, want to push a trivial new commit to get a new SHA, since homu seems busted here? |
974011f
to
9eb9c21
Compare
@bors: r=aturon 9eb9c21 |
9eb9c21
to
ad14891
Compare
Now that the `std::env` module has had some time to bake this commit marks most of its APIs as `#[stable]`. Some notable APIs that are **not** stable (and still use the same `env` feature gate) are: * `{set,get}_exit_status` - there are still questions about whether this is the right interface for setting/getting the exit status of a process. * `page_size` - this may change location in the future or perhaps name as well. This also effectively closes rust-lang#22122 as the variants of `VarError` are `#[stable]` now. (this is done intentionally)
⌛ Testing commit ad14891 with merge 3af0f10... |
Now that the `std::env` module has had some time to bake this commit marks most of its APIs as `#[stable]`. Some notable APIs that are **not** stable (and still use the same `env` feature gate) are: * `{set,get}_exit_status` - there are still questions about whether this is the right interface for setting/getting the exit status of a process. * `page_size` - this may change location in the future or perhaps name as well. This also effectively closes rust-lang#22122 as the variants of `VarError` are `#[stable]` now. (this is done intentionally)
💔 Test failed - auto-linux-64-x-android-t |
Now that the
std::env
module has had some time to bake this commit marks mostof its APIs as
#[stable]
. Some notable APIs that are not stable (and stilluse the same
env
feature gate) are:{set,get}_exit_status
- there are still questions about whether this is theright interface for setting/getting the exit status of a process.
page_size
- this may change location in the future or perhaps name as well.This also effectively closes #22122 as the variants of
VarError
are#[stable]
now. (this is done intentionally)