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: Allow creating ExitStatus from raw values #33224

Merged
merged 1 commit into from
May 9, 2016

Conversation

alexcrichton
Copy link
Member

Sometimes a process may be waited on externally from the standard library, in
which case it can be useful to create a raw ExitStatus structure to return.
This commit extends the existing Unix ExitStatusExt extension trait and adds a
new Windows-specific ExitStatusExt extension trait to do this. The methods are
currently called ExitStatus::from_raw.

cc #32713

@rust-highfive
Copy link
Collaborator

r? @aturon

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

/// Windows-specific extensions to `std::process::ExitStatus`
#[unstable(feature = "exit_status_from", issue = "32713")]
pub trait ExitStatusExt {
/// Creates a new `ExitStatus` from the raw underlying `i32` return value of
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

i32 when this function takes a u32?

Sometimes a process may be waited on externally from the standard library, in
which case it can be useful to create a raw `ExitStatus` structure to return.
This commit extends the existing Unix `ExitStatusExt` extension trait and adds a
new Windows-specific `ExitStatusExt` extension trait to do this. The methods are
currently called `ExitStatus::from_raw`.

cc rust-lang#32713
@aturon
Copy link
Member

aturon commented May 9, 2016

@bors: r+

@bors
Copy link
Contributor

bors commented May 9, 2016

📌 Commit 7f09b1f has been approved by aturon

Manishearth added a commit to Manishearth/rust that referenced this pull request May 9, 2016
…aturon

std: Allow creating ExitStatus from raw values

Sometimes a process may be waited on externally from the standard library, in
which case it can be useful to create a raw `ExitStatus` structure to return.
This commit extends the existing Unix `ExitStatusExt` extension trait and adds a
new Windows-specific `ExitStatusExt` extension trait to do this. The methods are
currently called `ExitStatus::from_raw`.

cc rust-lang#32713
Manishearth added a commit to Manishearth/rust that referenced this pull request May 9, 2016
…aturon

std: Allow creating ExitStatus from raw values

Sometimes a process may be waited on externally from the standard library, in
which case it can be useful to create a raw `ExitStatus` structure to return.
This commit extends the existing Unix `ExitStatusExt` extension trait and adds a
new Windows-specific `ExitStatusExt` extension trait to do this. The methods are
currently called `ExitStatus::from_raw`.

cc rust-lang#32713
bors added a commit that referenced this pull request May 9, 2016
Rollup of 10 pull requests

- Successful merges: #33129, #33224, #33370, #33383, #33431, #33474, #33480, #33496, #33509, #33514
- Failed merges:
@bors
Copy link
Contributor

bors commented May 9, 2016

⌛ Testing commit 7f09b1f with merge 0e7cb8b...

bors added a commit that referenced this pull request May 9, 2016
std: Allow creating ExitStatus from raw values

Sometimes a process may be waited on externally from the standard library, in
which case it can be useful to create a raw `ExitStatus` structure to return.
This commit extends the existing Unix `ExitStatusExt` extension trait and adds a
new Windows-specific `ExitStatusExt` extension trait to do this. The methods are
currently called `ExitStatus::from_raw`.

cc #32713
Manishearth added a commit to Manishearth/rust that referenced this pull request May 9, 2016
…aturon

std: Allow creating ExitStatus from raw values

Sometimes a process may be waited on externally from the standard library, in
which case it can be useful to create a raw `ExitStatus` structure to return.
This commit extends the existing Unix `ExitStatusExt` extension trait and adds a
new Windows-specific `ExitStatusExt` extension trait to do this. The methods are
currently called `ExitStatus::from_raw`.

cc rust-lang#32713
bors added a commit that referenced this pull request May 9, 2016
Rollup of 10 pull requests

- Successful merges: #33129, #33224, #33370, #33383, #33431, #33474, #33480, #33496, #33509, #33514
- Failed merges:
@bors bors merged commit 7f09b1f into rust-lang:master May 9, 2016
@alexcrichton alexcrichton deleted the create-exit-status branch May 12, 2016 21:59
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.

5 participants