Skip to content
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

Merged
merged 1 commit into from
Feb 28, 2015
Merged

Conversation

alexcrichton
Copy link
Member

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 #22122 as the variants of VarError are
#[stable] now. (this is done intentionally)

@alexcrichton
Copy link
Member Author

r? @aturon

@rust-highfive rust-highfive assigned aturon and unassigned nikomatsakis Feb 27, 2015
@rust-highfive
Copy link
Collaborator

r? @nikomatsakis

(rust_highfive has picked a reviewer for you, use r? to override)

@alexcrichton alexcrichton force-pushed the stabilize-env branch 2 times, most recently from edb40ce to 33c9e5d Compare February 27, 2015 19:09
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")]
Copy link
Member

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?

Copy link
Member Author

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.

@aturon
Copy link
Member

aturon commented Feb 27, 2015

@bors: r+ 974011f

another one bites the dust

@bors
Copy link
Contributor

bors commented Feb 27, 2015

🙀 974011f is not a valid commit SHA. Please try again with 33c9e5d.

@aturon
Copy link
Member

aturon commented Feb 27, 2015

@bors: r+ 974011f

@bors
Copy link
Contributor

bors commented Feb 27, 2015

🙀 974011f is not a valid commit SHA. Please try again with 33c9e5d.

@aturon
Copy link
Member

aturon commented Feb 27, 2015

@alexcrichton Hm, want to push a trivial new commit to get a new SHA, since homu seems busted here?

@alexcrichton
Copy link
Member Author

@bors: r=aturon 9eb9c21

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)
@alexcrichton
Copy link
Member Author

@bors: r=aturon ad14891

@bors
Copy link
Contributor

bors commented Feb 28, 2015

⌛ Testing commit ad14891 with merge 3af0f10...

Manishearth added a commit to Manishearth/rust that referenced this pull request Feb 28, 2015
 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)
@bors
Copy link
Contributor

bors commented Feb 28, 2015

💔 Test failed - auto-linux-64-x-android-t

@bors bors merged commit ad14891 into rust-lang:master Feb 28, 2015
@alexcrichton alexcrichton deleted the stabilize-env branch March 27, 2015 20:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

std::env::VarError should capture name
5 participants