bors
6f4ab9458a
Auto merge of #43710 - zackmdavis:field_init_shorthand_power_slam, r=Mark-Simulacrum
...
use field init shorthand EVERYWHERE
Like #43008 (f668999 ), but [(lacking reasons to be more timid)](https://github.com/rust-lang/rust/pull/43008#issuecomment-312463564 ) _much more aggressive_.
r? @Mark-Simulacrum
2017-08-16 04:00:24 +00:00
Zack M. Davis
1b6c9605e4
use field init shorthand EVERYWHERE
...
Like #43008 (f668999 ), but _much more aggressive_.
2017-08-15 15:29:17 -07:00
bors
f25c2283b3
Auto merge of #43635 - ids1024:backtrace-redox, r=alexcrichton
...
Make backtraces work on Redox, copying Unix implementation
The `backtrace/` directory here is the same as the Unix one, except for adding an implementation of `get_executable_filename`.
2017-08-15 19:27:29 +00:00
Guillaume Gomez
b1a742794e
Rollup merge of #43821 - NilSet:redox-dns, r=alexcrichton
...
Handle DNS label compression in more places in Redox name resolution
2017-08-13 11:03:12 +02:00
Guillaume Gomez
bc6659a8fe
Rollup merge of #43814 - Eijebong:fix_typos2, r=petrochenkov
...
Fix some typos
Follow up of #43794
If refined my script a little bit and found some more.
2017-08-13 11:03:11 +02:00
bors
0ed03e5490
Auto merge of #43348 - kennytm:fix-24658-doc-every-platform, r=alexcrichton
...
Expose all OS-specific modules in libstd doc.
1. Uses the special `--cfg dox` configuration passed by rustbuild when running `rustdoc`. Changes the `#[cfg(platform)]` into `#[cfg(any(dox, platform))]` so that platform-specific API are visible to rustdoc.
2. Since platform-specific implementations often won't compile correctly on other platforms, `rustdoc` is changed to apply `everybody_loops` to the functions during documentation and doc-test harness.
3. Since platform-specific code are documented on all platforms now, it could confuse users who found a useful API but is non-portable. Also, their examples will be doc-tested, so must be excluded when not testing on the native platform. An undocumented attribute `#[doc(cfg(...))]` is introduced to serve the above purposed.
Fixes #24658 (Does _not_ fully implement #1998 ).
2017-08-13 03:00:20 +00:00
Bastien Orivel
3ab86fbab2
Fix some typos
2017-08-12 14:01:11 +02:00
Thomas Levy
fb45233ed1
Handle DNS label compression in more places
2017-08-11 22:13:57 -07:00
Bastien Orivel
47cb3c5bc2
Fix some typos
2017-08-11 00:16:18 +02:00
kennytm
b4114ebe3a
Exposed all platform-specific documentation.
2017-08-10 13:43:59 +08:00
Ian Douglas Scott
9d67d5a71d
Simplify Redox backtrace/ to not include non-Redox implementations
2017-08-03 23:05:58 -07:00
Ian Douglas Scott
2fd4663fee
Make backtraces work on Redox, copying Unix implementation
2017-08-03 21:13:44 -07:00
bors
eae446c4dc
Auto merge of #43459 - ids1024:asrawfd, r=alexcrichton
...
Implement AsRawFd for Stdin, Stdout, and Stderr
https://github.com/rust-lang/rfcs/issues/2074
2017-08-04 02:15:04 +00:00
Jeremy Soller
a30092fbf6
Split FL and FD fcntls
2017-07-29 09:31:18 -06:00
Ian Douglas Scott
c83f97533a
Redox: Add JoinHandleExt (matching Unix version)
2017-07-29 09:31:18 -06:00
Ian Douglas Scott
e9c55d1f79
Correct 'stable' attribute
2017-07-25 16:44:25 -07:00
Ian Douglas Scott
85ef570e00
Implement AsRawFd for Stdin, Stdout, and Stderr
2017-07-24 14:46:42 -07:00
Mark Simulacrum
b43f58bc25
Rollup merge of #43304 - ids1024:path2, r=aturon
...
redox: handle multiple paths in PATH
2017-07-18 09:41:34 -06:00
Ian Douglas Scott
6f80cd7bfc
redox: handle multiple paths in PATH
2017-07-17 19:17:48 -07:00
NODA, Kai
2e8859ce4e
libstd: remove redundant & from &Path::new(...)
...
fn Path::new<S: AsRef ...>(s: &S) -> &Path
Signed-off-by: NODA, Kai <nodakai@gmail.com>
2017-07-18 00:07:09 +08:00
Corey Farwell
57bc82d637
Rollup merge of #43228 - redox-os:backtrace_fix, r=alexcrichton
...
Fix backtrace on Redox
This fixes sys::backtrace on Redox
2017-07-14 20:57:18 -07:00
Corey Farwell
351c476f6d
Rollup merge of #43202 - jackpot51:patch-1, r=sfackler
...
Fix sys::redox::net::tcp
A change to the upper level API needed to be filtered down
2017-07-14 20:57:16 -07:00
Jeremy Soller
5757e05619
Fix backtrace on Redox
2017-07-13 20:07:37 -06:00
Steve Klabnik
da3f5b80ed
Rollup merge of #43204 - jackpot51:patch-3, r=alexcrichton
...
Implement fs::rename in sys::redox
This uses a simple implementation of copy + unlink. Redox does not have a rename or link system call for a faster implementation.
2017-07-13 10:45:22 -04:00
Jeremy Soller
4259ae6475
Update fs.rs
2017-07-12 22:16:35 -06:00
Jeremy Soller
21f2ace8cf
Update mod.rs
2017-07-12 20:48:04 -06:00
Jeremy Soller
362dd8a986
Update fs.rs
2017-07-12 20:40:43 -06:00
Jeremy Soller
bd9428a46b
Update mod.rs
2017-07-12 20:39:02 -06:00
Jeremy Soller
0d617ce4c9
Update tcp.rs
2017-07-12 20:37:18 -06:00
Mark Simulacrum
6aeb0f0b2e
Rollup merge of #43100 - ids1024:stat2, r=aturon
...
Redox: add stat methods(); support is_symlink()
2017-07-12 06:58:47 -06:00
Ian Douglas Scott
51260f4a6d
Redox: Use O_NOFOLLOW for lstat()
2017-07-11 15:05:17 -07:00
Ian Douglas Scott
59981e4057
Redox: Fix Condvar.wait(); do not lock mutex twice
...
The atomic_xchg() loop locks the mutex, so the call to mutex_lock is
incorrect, and blocks.
2017-07-07 08:34:48 -07:00
Steven Fackler
8c92da3c51
Implement TcpStream::connect_timeout
...
This breaks the "single syscall rule", but it's really annoying to hand
write and is pretty foundational.
2017-07-06 19:35:49 -07:00
Ian Douglas Scott
4d58b048a8
Redox: add stat methods(); support is_symlink()
2017-07-06 17:34:51 -07:00
Mark Simulacrum
8abc58e6b9
Rollup merge of #42975 - ids1024:symlink2, r=aturon
...
redox: symlink and readlink
2017-07-04 07:41:40 -06:00
Ian Douglas Scott
3456608aae
Fix long line
2017-06-30 13:39:14 -07:00
Ian Douglas Scott
8ed83f4aaf
Fix Redox build, apparently broken by #42687
2017-06-29 18:18:32 -07:00
Ian Douglas Scott
8ee6bddf0b
redox: symlink and readlink
2017-06-29 17:43:44 -07:00
bors
dc2003b7cc
Auto merge of #42848 - ids1024:redox-fix, r=sfackler
...
Fix Redox build, broken in ecbb896b9e
2017-06-29 06:20:17 +00:00
Mark Simulacrum
d22eb081ef
Rollup merge of #42783 - ids1024:redox-env, r=sfackler
...
Redox: Use create() instead of open() when setting env variable
See https://github.com/redox-os/kernel/pull/25 .
2017-06-23 06:02:08 -06:00
kennytm
4711982314
Removed as many "```ignore" as possible.
...
Replaced by adding extra imports, adding hidden code (`# ...`), modifying
examples to be runnable (sorry Homura), specifying non-Rust code, and
converting to should_panic, no_run, or compile_fail.
Remaining "```ignore"s received an explanation why they are being ignored.
2017-06-23 15:31:53 +08:00
Ian Douglas Scott
87f6d6249c
Fix Redox build, broken in ecbb896b9e
2017-06-22 19:14:26 -07:00
bors
6f01c84fc8
Auto merge of #42798 - stepancheg:args-debug, r=sfackler
...
Better Debug for Args and ArgsOs
Display actual args instead of two dots.
2017-06-22 10:34:21 +00:00
Stepan Koltsov
275f9a04af
Better Debug for Args and ArgsOs
...
Display actual args instead of two dots.
2017-06-21 15:40:45 +03:00
Steven Fackler
ecbb896b9e
Add Read::initializer.
...
This is an API that allows types to indicate that they can be passed
buffers of uninitialized memory which can improve performance.
2017-06-20 20:26:22 -07:00
Ian Douglas Scott
9f91a4df83
Redox: Use create() instead of open() when setting env variable
2017-06-20 16:04:38 -07:00
Stepan Koltsov
ac96fd7787
Avoid allocations in Debug for os_str
...
Fixes #38879
2017-06-15 20:42:37 +01:00
Josh Stone
9debe91675
Add conversions from File and Child* handles to Stdio
...
`Stdio` now implements `From<ChildStdin>`, `From<ChildStdout>`,
`From<ChildStderr>`, and `From<File>`.
The `Command::stdin`/`stdout`/`stderr` methods now take any type that
implements `Into<Stdio>`.
This makes it much easier to write shell-like command chains, piping to
one another and redirecting to and from files. Otherwise one would need
to use the unsafe and OS-specific `from_raw_fd` or `from_raw_handle`.
2017-06-06 15:42:55 -07:00
Jeremy Soller
f3286fd439
Switch to repr(C) for syscall structs
2017-06-02 20:57:46 -06:00
Ian Douglas Scott
f4147e587d
Implement requires_synchronized_create() for Redox
...
This was breaking the libstd build for Redox.
2017-05-21 13:23:42 -07:00