summary refs log tree commit diff
path: root/src/libstd
AgeCommit message (Collapse)AuthorLines
2016-01-19Add an impl for Box<Error> from &str.Michael Sproul-0/+7
2016-01-19Add an impl for Box<Error> from String.Michael Sproul-0/+9
Closes #30156.
2016-01-12Fix extra space in str docsSteve Klabnik-1/+1
2015-12-09doc: these are just renames, so avoid duplicationTshepang Lekhonkhobe-7/+2
2015-12-07Auto merge of #30188 - tshepang:lookup_addr-example, r=alexcrichtonbors-0/+16
2015-12-06doc: add example for std::net::lookup_addrTshepang Lekhonkhobe-0/+16
2015-12-06Auto merge of #30187 - alexcrichton:stabilize-1.6, r=aturonbors-121/+146
This commit is the standard API stabilization commit for the 1.6 release cycle. The list of issues and APIs below have all been through their cycle-long FCP and the libs team decisions are listed below Stabilized APIs * `Read::read_exact` * `ErrorKind::UnexpectedEof` (renamed from `UnexpectedEOF`) * libcore -- this was a bit of a nuanced stabilization, the crate itself is now marked as `#[stable]` and the methods appearing via traits for primitives like `char` and `str` are now also marked as stable. Note that the extension traits themeselves are marked as unstable as they're imported via the prelude. The `try!` macro was also moved from the standard library into libcore to have the same interface. Otherwise the functions all have copied stability from the standard library now. * `fs::DirBuilder` * `fs::DirBuilder::new` * `fs::DirBuilder::recursive` * `fs::DirBuilder::create` * `os::unix::fs::DirBuilderExt` * `os::unix::fs::DirBuilderExt::mode` * `vec::Drain` * `vec::Vec::drain` * `string::Drain` * `string::String::drain` * `vec_deque::Drain` * `vec_deque::VecDeque::drain` * `collections::hash_map::Drain` * `collections::hash_map::HashMap::drain` * `collections::hash_set::Drain` * `collections::hash_set::HashSet::drain` * `collections::binary_heap::Drain` * `collections::binary_heap::BinaryHeap::drain` * `Vec::extend_from_slice` (renamed from `push_all`) * `Mutex::get_mut` * `Mutex::into_inner` * `RwLock::get_mut` * `RwLock::into_inner` * `Iterator::min_by_key` (renamed from `min_by`) * `Iterator::max_by_key` (renamed from `max_by`) Deprecated APIs * `ErrorKind::UnexpectedEOF` (renamed to `UnexpectedEof`) * `OsString::from_bytes` * `OsStr::to_cstring` * `OsStr::to_bytes` * `fs::walk_dir` and `fs::WalkDir` * `path::Components::peek` * `slice::bytes::MutableByteVector` * `slice::bytes::copy_memory` * `Vec::push_all` (renamed to `extend_from_slice`) * `Duration::span` * `IpAddr` * `SocketAddr::ip` * `Read::tee` * `io::Tee` * `Write::broadcast` * `io::Broadcast` * `Iterator::min_by` (renamed to `min_by_key`) * `Iterator::max_by` (renamed to `max_by_key`) * `net::lookup_addr` New APIs (still unstable) * `<[T]>::sort_by_key` (added to mirror `min_by_key`) Closes #27585 Closes #27704 Closes #27707 Closes #27710 Closes #27711 Closes #27727 Closes #27740 Closes #27744 Closes #27799 Closes #27801 cc #27801 (doesn't close as `Chars` is still unstable) Closes #28968
2015-12-05std: Stabilize APIs for the 1.6 releaseAlex Crichton-121/+146
This commit is the standard API stabilization commit for the 1.6 release cycle. The list of issues and APIs below have all been through their cycle-long FCP and the libs team decisions are listed below Stabilized APIs * `Read::read_exact` * `ErrorKind::UnexpectedEof` (renamed from `UnexpectedEOF`) * libcore -- this was a bit of a nuanced stabilization, the crate itself is now marked as `#[stable]` and the methods appearing via traits for primitives like `char` and `str` are now also marked as stable. Note that the extension traits themeselves are marked as unstable as they're imported via the prelude. The `try!` macro was also moved from the standard library into libcore to have the same interface. Otherwise the functions all have copied stability from the standard library now. * The `#![no_std]` attribute * `fs::DirBuilder` * `fs::DirBuilder::new` * `fs::DirBuilder::recursive` * `fs::DirBuilder::create` * `os::unix::fs::DirBuilderExt` * `os::unix::fs::DirBuilderExt::mode` * `vec::Drain` * `vec::Vec::drain` * `string::Drain` * `string::String::drain` * `vec_deque::Drain` * `vec_deque::VecDeque::drain` * `collections::hash_map::Drain` * `collections::hash_map::HashMap::drain` * `collections::hash_set::Drain` * `collections::hash_set::HashSet::drain` * `collections::binary_heap::Drain` * `collections::binary_heap::BinaryHeap::drain` * `Vec::extend_from_slice` (renamed from `push_all`) * `Mutex::get_mut` * `Mutex::into_inner` * `RwLock::get_mut` * `RwLock::into_inner` * `Iterator::min_by_key` (renamed from `min_by`) * `Iterator::max_by_key` (renamed from `max_by`) Deprecated APIs * `ErrorKind::UnexpectedEOF` (renamed to `UnexpectedEof`) * `OsString::from_bytes` * `OsStr::to_cstring` * `OsStr::to_bytes` * `fs::walk_dir` and `fs::WalkDir` * `path::Components::peek` * `slice::bytes::MutableByteVector` * `slice::bytes::copy_memory` * `Vec::push_all` (renamed to `extend_from_slice`) * `Duration::span` * `IpAddr` * `SocketAddr::ip` * `Read::tee` * `io::Tee` * `Write::broadcast` * `io::Broadcast` * `Iterator::min_by` (renamed to `min_by_key`) * `Iterator::max_by` (renamed to `max_by_key`) * `net::lookup_addr` New APIs (still unstable) * `<[T]>::sort_by_key` (added to mirror `min_by_key`) Closes #27585 Closes #27704 Closes #27707 Closes #27710 Closes #27711 Closes #27727 Closes #27740 Closes #27744 Closes #27799 Closes #27801 cc #27801 (doesn't close as `Chars` is still unstable) Closes #28968
2015-12-05Auto merge of #30177 - retep998:handling-threads, r=alexcrichtonbors-0/+122
Allows a `HANDLE` to be extracted from a `JoinHandle` on Windows. Allows a `pthread_t` to be extracted from a `JoinHandle` everywhere else. Because https://github.com/rust-lang/rust/pull/29461 was closed. r? @alexcrichton
2015-12-05Remove allocations in `impl Display for Ipv6Addr`Simon Sapin-11/+11
2015-12-04Add JoinHandleExt to get the pthread_t on unix platformsPeter Atashian-0/+79
Signed-off-by: Peter Atashian <retep998@gmail.com>
2015-12-04AsRawHandle and IntoRawHandle for JoinHandlePeter Atashian-0/+43
This allows users to get the HANDLE of a spawned thread on Windows Signed-off-by: Peter Atashian <retep998@gmail.com>
2015-12-04Auto merge of #30173 - sgrif:sg-fix-time-bug, r=alexcrichtonbors-2/+7
Currently if you add a duration which should lead to 0 nanos and 1 additional second, we end up with no additional seconds, and 1000000000 nanos.
2015-12-04Fix the time overflow on mac as wellSean Griffin-1/+1
2015-12-03doc: add example for std::fs::DirBuilderTshepang Lekhonkhobe-0/+14
2015-12-03Fix tests for SystemTime addition on mac and iosSean Griffin-2/+2
Those platforms don't support nanosecond precision, so adding 1 nanosecond does nothing.
2015-12-02Fixed make tidy errorSean Griffin-1/+2
2015-12-02Ensure two `SystemTime`s are equal when nanos add to exactly 1BSean Griffin-1/+5
Currently if you add a duration which should lead to 0 nanos and 1 additional second, we end up with no additional seconds, and 1000000000 nanos.
2015-12-02Auto merge of #30160 - adambadawy:fix_wait_with_output_typo, r=blussbors-1/+1
r? @steveklabnik
2015-12-01Fix typo in src/libstd/process.rsAdam Badawy-1/+1
2015-12-01Rollup merge of #30150 - steveklabnik:fix_exe_suffix, r=alexcrichtonSteve Klabnik-4/+6
2015-12-01Rollup merge of #30129 - tbu-:pr_doc_arrays_coerce, r=steveklabnikSteve Klabnik-6/+6
Fixes #29993.
2015-12-01Auto merge of #30129 - tbu-:pr_doc_arrays_coerce, r=steveklabnikbors-6/+6
Fixes #29993.
2015-12-01Small fix to EXE_SUFFIX and DLL_EXTENSION docsSteve Klabnik-4/+6
2015-12-01Auto merge of #30118 - alexcrichton:fix-time-again, r=aturonbors-1/+1
I believe that because Windows' unit of resolution is 100ns that this unit of time will ensure that the assertions will hold true as it's representable in the native format. cc #29970
2015-12-01Auto merge of #30057 - steveklabnik:doc_str, r=alexcrichtonbors-22/+42
Part of #29338
2015-12-01Arrays don't dereference but coerce to slicesTobias Bucher-6/+6
Fixes #29993.
2015-11-30Auto merge of #30080 - durka:patch-10, r=alexcrichtonbors-4/+4
Fixes #30073. The input to `cfg!` is a meta attribute, but not _any_ meta attribute (e.g. `cfg!(allow(dead_code))` doesn't compile). But the macro_rules syntax can't quite express this, so I added a note to the doc.
2015-11-30Better docs for the str primitiveSteve Klabnik-22/+42
Part of #29338
2015-11-30std: Bump time margin in std::time testsAlex Crichton-1/+1
I believe that because Windows' unit of resolution is 100ns that this unit of time will ensure that the assertions will hold true as it's representable in the native format. cc #29970
2015-11-29tweak cfg! doc commentAlex Burka-3/+3
2015-11-29Fix #30093Jack Fransham-1/+1
2015-11-28Auto merge of #30092 - semarie:to_socket_addr_str_bad, r=alexcrichtonbors-2/+2
I don't reproduce it on severals hosts (virtual or real), so I can't debug it. As Bitrig has disabled this test too, I will follow the same here. r? @alexcrichton
2015-11-28disable net::addr::to_socket_addr_str_bad test under openbsdSébastien Marie-2/+2
I don't reproduce it on severals hosts (virtual or real), so I can't debug it. As Bitrig has disabled this test too, I will follow the same here.
2015-11-26fix docs for compiler builtin macrosAlex Burka-3/+3
2015-11-26Auto merge of #30061 - tshepang:doc-time, r=brsonbors-13/+12
2015-11-26doc: this is already mentioned in previous paragraph, and is harder to readTshepang Lekhonkhobe-3/+2
2015-11-25doc: fix type nameTshepang Lekhonkhobe-1/+1
2015-11-25doc: add a pauseTshepang Lekhonkhobe-2/+3
2015-11-25doc: split overlong sentenceTshepang Lekhonkhobe-2/+2
2015-11-25doc: add missing commasTshepang Lekhonkhobe-2/+2
2015-11-25doc: fix grammarTshepang Lekhonkhobe-1/+1
2015-11-25doc: remove info repeated on next paragraphTshepang Lekhonkhobe-2/+1
2015-11-25Remove all uses of `#[staged_api]`Vadim Petrochenkov-1/+1
2015-11-25Auto merge of #30052 - Ryman:bind_docs, r=apasel422bors-1/+1
`socket_addr` was renamed to `local_addr` in 1.0beta. See: f798674b86382929ca17c88de422a6e2fdb27f2a r? @steveklabnik
2015-11-25Fix docs for TcpListener::bindKevin Butler-1/+1
`socket_addr` was renamed to `local_addr` in 1.0beta. See: f798674b86382929ca17c88de422a6e2fdb27f2a
2015-11-25Rollup merge of #30013 - steveklabnik:doc_char, r=brsonManish Goregaokar-11/+72
Part of https://github.com/rust-lang/rust/issues/29333
2015-11-24Auto merge of #30016 - alexcrichton:fix-off-by-one, r=brsonbors-14/+24
Typical algebra currently doesn't work on the types in std::time currently (see [this comment][comment]), so tweak the tests to account for this property. [comment]: https://github.com/rust-lang/rust/issues/29866#issuecomment-159093809 Closes #29970
2015-11-24Fix up docs for charSteve Klabnik-11/+72
Part of https://github.com/rust-lang/rust/issues/29333
2015-11-24Auto merge of #30006 - ntrepid8:skip-check-for-DYLD-libs-in-child-proc, ↵bors-0/+1
r=alexcrichton It seems that OS X El Capitan does not pass DYLD_* environment variables to child processes anymore. See this link: https://forums.developer.apple.com/thread/9233 The causes a test in `src/libstd/process.rs' to fail when those environment variables are not found in the child process. This PR skips those variables similar to how the Windows envars that start with `=` are skipped.