- 02 10月, 2014 1 次提交
-
-
由 Aaron Turon 提交于
This commit removes the `iotest!` macro from `std::io`. The macro was primarily used to ensure that all io-related tests were run on both libnative and libgreen/librustuv. However, now that the librustuv stack is being removed, the macro is no longer needed. See the [runtime removal RFC](https://github.com/rust-lang/rfcs/pull/230) for more context. [breaking-change]
-
- 01 10月, 2014 2 次提交
-
-
由 Ricardo M. Correia 提交于
In some build environments (such as chrooted Nix builds), `env` can only be found in the explicitly-provided PATH, not in default places such as /bin or /usr/bin. So we need to pass-through PATH when spawning the `env` sub-process. Fixes #17617
-
由 Steven Fackler 提交于
-
- 18 9月, 2014 1 次提交
-
-
由 Vadim Chugunov 提交于
-
- 17 9月, 2014 2 次提交
-
-
由 Vadim Chugunov 提交于
-
由 Aaron Turon 提交于
-
- 29 8月, 2014 1 次提交
-
-
由 Aaron Turon 提交于
-
- 17 8月, 2014 1 次提交
-
-
由 Patrick Walton 提交于
declared with the same name in the same scope. This breaks several common patterns. First are unused imports: use foo::bar; use baz::bar; Change this code to the following: use baz::bar; Second, this patch breaks globs that import names that are shadowed by subsequent imports. For example: use foo::*; // including `bar` use baz::bar; Change this code to remove the glob: use foo::{boo, quux}; use baz::bar; Or qualify all uses of `bar`: use foo::{boo, quux}; use baz; ... baz::bar ... Finally, this patch breaks code that, at top level, explicitly imports `std` and doesn't disable the prelude. extern crate std; Because the prelude imports `std` implicitly, there is no need to explicitly import it; just remove such directives. The old behavior can be opted into via the `import_shadowing` feature gate. Use of this feature gate is discouraged. This implements RFC #116. Closes #16464. [breaking-change]
-
- 14 8月, 2014 2 次提交
-
-
由 Brian Anderson 提交于
Add tests. Also fix a bunch of broken time tests.
-
由 Brian Anderson 提交于
Rename io::timer::sleep, Timer::sleep, Timer::oneshot, Timer::periodic, to sleep_ms, oneshot_ms, periodic_ms. These functions all take an integer and interpret it as milliseconds. Replacement functions will be added that take Duration. [breaking-change]
-
- 13 8月, 2014 1 次提交
-
-
由 Ivan Petkov 提交于
* The caller should be responsible for cleaning up file descriptors * If a caller safely creates a file descriptor (via native::io::file::open) the returned structure (FileDesc) will try to clean up the file, failing in the process and writing error messages to the screen. * This should not happen as the caller has no public interface for telling the FileDesc structure to NOT free the underlying fd. * Alternatively, if another file is opened under the same fd held by the FileDesc structure returned by native::io::file::open, it will close the wrong file upon destruction.
-
- 16 7月, 2014 3 次提交
-
-
由 Adolfo Ochagavía 提交于
-
由 Adolfo Ochagavía 提交于
Use `String::from_utf8_lossy` instead [breaking-change]
-
由 Adolfo Ochagavía 提交于
Use `String::from_utf8` instead [breaking-change]
-
- 14 7月, 2014 1 次提交
-
-
由 Aaron Turon 提交于
This PR is the outcome of the library stabilization meeting for the `liballoc::owned` and `libcore::cell` modules. Aside from the stability attributes, there are a few breaking changes: * The `owned` modules is now named `boxed`, to better represent its contents. (`box` was unavailable, since it's a keyword.) This will help avoid the misconception that `Box` plays a special role wrt ownership. * The `AnyOwnExt` extension trait is renamed to `BoxAny`, and its `move` method is renamed to `downcast`, in both cases to improve clarity. * The recently-added `AnySendOwnExt` extension trait is removed; it was not being used and is unnecessary. [breaking-change]
-
- 11 7月, 2014 1 次提交
-
-
由 Aaron Turon 提交于
This commit changes the `io::process::Command` API to provide fine-grained control over the environment: * The `env` method now inserts/updates a key/value pair. * The `env_remove` method removes a key from the environment. * The old `env` method, which sets the entire environment in one shot, is renamed to `env_set_all`. It can be used in conjunction with the finer-grained methods. This renaming is a breaking change. To support these new methods, the internal `env` representation for `Command` has been changed to an optional `HashMap` holding owned `CString`s (to support non-utf8 data). The `HashMap` is only materialized if the environment is updated. The implementation does not try hard to avoid allocation, since the cost of launching a process will dwarf any allocation cost. This patch also adds `PartialOrd`, `Eq`, and `Hash` implementations for `CString`. [breaking-change]
-
- 10 7月, 2014 1 次提交
-
-
由 Jorge Aparicio 提交于
-
- 09 7月, 2014 1 次提交
-
-
由 Richo Healey 提交于
[breaking-change]
-
- 27 6月, 2014 1 次提交
-
-
由 OGINO Masanori 提交于
We use re-exported pathes (e.g. std::io::Command) and original ones (e.g. std::io::process::Command) together in examples now. Using re-exported ones consistently avoids confusion. Signed-off-by: NOGINO Masanori <masanori.ogino@gmail.com>
-
- 25 6月, 2014 1 次提交
-
-
由 Niko Matsakis 提交于
This breaks a fair amount of code. The typical patterns are: * `for _ in range(0, 10)`: change to `for _ in range(0u, 10)`; * `println!("{}", 3)`: change to `println!("{}", 3i)`; * `[1, 2, 3].len()`: change to `[1i, 2, 3].len()`. RFC #30. Closes #6023. [breaking-change]
-
- 17 6月, 2014 1 次提交
-
-
由 Alex Crichton 提交于
Forking off a child which survives the parent is often a useful task, and is currently not possible because the Process type will invoke `wait()` in its destructor in order to prevent leaking resources. This function adds a new safe method, `forget`, which can be used to consume an instance of `Process` which will then not call `wait` in the destructor. This new method is clearly documented as a leak of resources, but it must be forcibly opted in to. Closes #14467
-
- 16 6月, 2014 1 次提交
-
-
由 Alex Crichton 提交于
-
- 12 6月, 2014 1 次提交
-
-
由 Alex Crichton 提交于
The following features have been removed * box [a, b, c] * ~[a, b, c] * box [a, ..N] * ~[a, ..N] * ~[T] (as a type) * deprecated_owned_vector lint All users of ~[T] should move to using Vec<T> instead.
-
- 09 6月, 2014 1 次提交
-
-
由 Joseph Crail 提交于
-
- 07 6月, 2014 1 次提交
-
-
由 Alex Crichton 提交于
-
- 02 6月, 2014 1 次提交
-
-
由 Alex Crichton 提交于
This completes the last stage of the renaming of the comparison hierarchy of traits. This change renames TotalEq to Eq and TotalOrd to Ord. In the future the new Eq/Ord will be filled out with their appropriate methods, but for now this change is purely a renaming change. [breaking-change]
-
- 31 5月, 2014 1 次提交
-
-
由 Alex Crichton 提交于
This is part of the ongoing renaming of the equality traits. See #12517 for more details. All code using Eq/Ord will temporarily need to move to Partial{Eq,Ord} or the Total{Eq,Ord} traits. The Total traits will soon be renamed to {Eq,Ord}. cc #12517 [breaking-change]
-
- 28 5月, 2014 1 次提交
-
-
由 Richo Healey 提交于
[breaking-change]
-
- 26 5月, 2014 1 次提交
-
-
由 Kevin Ballard 提交于
-
- 25 5月, 2014 1 次提交
-
-
由 Richo Healey 提交于
[breaking-change]
-
- 23 5月, 2014 2 次提交
-
-
由 Patrick Walton 提交于
[breaking-change]
-
由 Patrick Walton 提交于
-
- 22 5月, 2014 1 次提交
-
-
由 Huon Wilson 提交于
-
- 16 5月, 2014 2 次提交
-
-
由 Alex Crichton 提交于
-
由 Alex Crichton 提交于
1. Wherever the `buf` field of a `Formatter` was used, the `Formatter` is used instead. 2. The usage of `write_fmt` is minimized as much as possible, the `write!` macro is preferred wherever possible. 3. Usage of `fmt::write` is minimized, favoring the `write!` macro instead.
-
- 15 5月, 2014 1 次提交
-
-
由 Aaron Turon 提交于
The existing APIs for spawning processes took strings for the command and arguments, but the underlying system may not impose utf8 encoding, so this is overly limiting. The assumption we actually want to make is just that the command and arguments are viewable as [u8] slices with no interior NULLs, i.e., as CStrings. The ToCStr trait is a handy bound for types that meet this requirement (such as &str and Path). However, since the commands and arguments are often a mixture of strings and paths, it would be inconvenient to take a slice with a single T: ToCStr bound. So this patch revamps the process creation API to instead use a builder-style interface, called `Command`, allowing arguments to be added one at a time with differing ToCStr implementations for each. The initial cut of the builder API has some drawbacks that can be addressed once issue #13851 (libstd as a facade) is closed. These are detailed as FIXMEs. Closes #11650. [breaking-change]
-
- 14 5月, 2014 1 次提交
-
-
由 Alex Crichton 提交于
This implements set_timeout() for std::io::Process which will affect wait() operations on the process. This follows the same pattern as the rest of the timeouts emerging in std::io::net. The implementation was super easy for everything except libnative on unix (backwards from usual!), which required a good bit of signal handling. There's a doc comment explaining the strategy in libnative. Internally, this also required refactoring the "helper thread" implementation used by libnative to allow for an extra helper thread (not just the timer). This is a breaking change in terms of the io::Process API. It is now possible for wait() to fail, and subsequently wait_with_output(). These two functions now return IoResult<T> due to the fact that they can time out. Additionally, the wait_with_output() function has moved from taking `&mut self` to taking `self`. If a timeout occurs while waiting with output, the semantics are undesirable in almost all cases if attempting to re-wait on the process. Equivalent functionality can still be achieved by dealing with the output handles manually. [breaking-change] cc #13523
-
- 13 5月, 2014 1 次提交
-
-
由 Yehuda Katz 提交于
-
- 09 5月, 2014 1 次提交
-
-
由 Kevin Ballard 提交于
API Changes: - get_host_addresses() returns IoResult<Vec<IpAddr>> - Process.extra_io is Vec<Option<io::PipeStream>>
-
- 07 5月, 2014 1 次提交
-
-
由 Alex Crichton 提交于
This moves as much allocation as possible from teh std::str module into core::str. This includes essentially all non-allocating functionality, mostly iterators and slicing and such. This primarily splits the Str trait into only having the as_slice() method, adding a new StrAllocating trait to std::str which contains the relevant new allocation methods. This is a breaking change if any of the methods of "trait Str" were overriden. The old functionality can be restored by implementing both the Str and StrAllocating traits. [breaking-change]
-