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

Add std::process #22119

Merged
merged 1 commit into from
Feb 14, 2015
Merged

Add std::process #22119

merged 1 commit into from
Feb 14, 2015

Conversation

aturon
Copy link
Member

@aturon aturon commented Feb 9, 2015

Per RFC 579, this commit
adds a new std::process module. This module is largely based on the
existing std::old_io::process module, but refactors the API to use
OsStr and other new standards set out by IO reform.

The existing module is not yet deprecated, to allow for the new API to
get a bit of testing before a mass migration to it.

@aturon
Copy link
Member Author

aturon commented Feb 9, 2015

r? @alexcrichton

@rust-highfive rust-highfive assigned alexcrichton and unassigned brson Feb 9, 2015
@rust-highfive
Copy link
Collaborator

r? @brson

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

@aturon
Copy link
Member Author

aturon commented Feb 9, 2015

This is WIP for two reasons:

  1. Not yet passing tests on Windows; it's close.
  2. It still uses old_io in a few places, since I didn't want to duplicate work in the std::fs PR.

#[cfg(windows)] const MustDieSignal: int = 9;
/// Signal a process to exit immediately, forcibly killing it. Corresponds to
/// SIGKILL on unix platforms.
#[cfg(not(windows))] const MustDieSignal: int = libc::SIGKILL as int;
Copy link
Member

Choose a reason for hiding this comment

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

I think that in general we've had pretty good success with trying to have as few #[cfg] directives as possible, could this logic be pushed into each respective sys module?

Copy link
Contributor

Choose a reason for hiding this comment

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

This should probably not be an int.

@bors
Copy link
Contributor

bors commented Feb 13, 2015

💔 Test failed - auto-win-32-nopt-t

@bors
Copy link
Contributor

bors commented Feb 13, 2015

💔 Test failed - auto-win-64-opt

@aturon
Copy link
Member Author

aturon commented Feb 13, 2015

@bors: retry

@bors
Copy link
Contributor

bors commented Feb 13, 2015

⌛ Testing commit 1a72dac with merge d05755d...

@bors
Copy link
Contributor

bors commented Feb 13, 2015

💔 Test failed - auto-win-32-opt

@aturon aturon force-pushed the new-process branch 3 times, most recently from 9c50a35 to 0f697c2 Compare February 14, 2015 00:00
@aturon
Copy link
Member Author

aturon commented Feb 14, 2015

@bors: r=alexcrichton 0f697c2 p=1

@bors
Copy link
Contributor

bors commented Feb 14, 2015

⌛ Testing commit 0f697c2 with merge 1ac4113...

@bors
Copy link
Contributor

bors commented Feb 14, 2015

💔 Test failed - auto-win-32-nopt-t

@aturon
Copy link
Member Author

aturon commented Feb 14, 2015

@bors: r=alexcrichton bec4af2 p=1

@bors
Copy link
Contributor

bors commented Feb 14, 2015

⌛ Testing commit bec4af2 with merge 972bafc...

@bors
Copy link
Contributor

bors commented Feb 14, 2015

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

Per [RFC 579](rust-lang/rfcs#579), this commit
adds a new `std::process` module. This module is largely based on the
existing `std::old_io::process` module, but refactors the API to use
`OsStr` and other new standards set out by IO reform.

The existing module is not yet deprecated, to allow for the new API to
get a bit of testing before a mass migration to it.
@aturon
Copy link
Member Author

aturon commented Feb 14, 2015

@bors: r=alexcrichton 4175f1c p=1

@bors
Copy link
Contributor

bors commented Feb 14, 2015

⌛ Testing commit 4175f1c with merge df54632...

bors added a commit that referenced this pull request Feb 14, 2015
Per [RFC 579](rust-lang/rfcs#579), this commit
adds a new `std::process` module. This module is largely based on the
existing `std::old_io::process` module, but refactors the API to use
`OsStr` and other new standards set out by IO reform.

The existing module is not yet deprecated, to allow for the new API to
get a bit of testing before a mass migration to it.
@bors bors merged commit 4175f1c into rust-lang:master Feb 14, 2015
@aturon aturon mentioned this pull request Feb 18, 2015
91 tasks
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.

10 participants