| Age | Commit message (Collapse) | Author | Lines |
|
r=alexcrichton
Ignore unknown address types when looking up hosts
Previously, any function using a `ToSocketAddrs` input would fail if
passed a hostname that resolves to an address type different from the
ones recognized by Rust.
This also changes the `LookupHost` iterator to only include the known
address types, as a result, it doesn't have to return `Result`s any
more, which are likely misinterpreted as failed name lookups.
|
|
|
|
There isn't anything deprecated being used in this function.
|
|
|
|
|
|
|
|
Previously, any function using a `ToSocketAddrs` input would fail if
passed a hostname that resolves to an address type different from the
ones recognized by Rust.
This also changes the `LookupHost` iterator to only include the known
address types, as a result, it doesn't have to return `Result`s any
more, which are likely misinterpreted as failed name lookups.
|
|
Add doc example for `std::io::sink`.
None
|
|
Add doc example for `std::io::repeat`.
None
|
|
Minor rewrite of `std::io::empty` doc example.
None
|
|
Expand `std::path::Component` documentation.
Indicate how it gets created and add an example.
|
|
Use the correct types in float examples
r? @steveklabnik
|
|
Add example for `std::thread::sleep`.
None
|
|
|
|
Remove unnecessary hidden `foo` function.
Demonstrate this emptiness of the resulting string.
Combine imports.
|
|
|
|
|
|
Indicate how it gets created and add an example.
|
|
Indicate how the `std::path::Components` struct is created.
None
|
|
Add hyperlinks to `std::fs` functions from `std::path`.
None
|
|
Add doc example for `std::thread::Builder::name`.
None
|
|
Parameters in doc comment should be formatted code-like.
None
|
|
|
|
|
|
Indicate how the `JoinHandle` struct is created.
None
|
|
|
|
Use `Option::expect` instead of `unwrap_or_else` with `panic!`.
None
|
|
Don't ignore errors of syscalls in std::sys::unix::fd
If any of these syscalls fail, it indicates a programmer error that
should not be silently ignored.
|
|
|
|
Use `len` instead of `size_hint` where appropiate
This makes it clearer that we're not just looking for a lower bound but
rather know that the iterator is an `ExactSizeIterator`.
|
|
|
|
|
|
std: Fix up stabilization discrepancies
* Remove the deprecated `CharRange` type which was forgotten to be removed
awhile back.
* Stabilize the `os::$platform::raw::pthread_t` type which was intended to be
stabilized as part of #32804
|
|
|
|
upgrade thread_local! invocation syntax
Allows declaring multiple statics in one macro invocation, and supports attaching attributes to the generated items. In particular, `#![forbid(missing_docs, unused)]` is now tenable on a crate/module containing thread locals.
For an example see [here](https://is.gd/aVFZZF). This change is fully backwards compatible as far as I can tell.
cc @frankmcsherry
|
|
* Remove the deprecated `CharRange` type which was forgotten to be removed
awhile back.
* Stabilize the `os::$platform::raw::pthread_t` type which was intended to be
stabilized as part of #32804
|
|
If any of these syscalls fail, it indicates a programmer error that
should not be silently ignored.
|
|
This makes it clearer that we're not just looking for a lower bound but
rather know that the iterator is an `ExactSizeIterator`.
|
|
Allows declaring multiple statics in one macro invocation, and supports attaching attributes to the generated items.
|
|
|
|
|
|
|
|
Mark concat_idents! unstable
This is mostly just a documentation fix as I don't think stability
attributes have any effect on macros.
[before](https://doc.rust-lang.org/nightly/std/macro.concat_idents!.html) [after](https://ollie27.github.io/rust_doc_test/std/macro.concat_idents!.html)
|
|
Fix overflow error in thread::sleep
Fixes #34330
I added a test to have a more clear error inside the function. Since `time_t` is `i64` and we expect `u64`, maybe we should changed the awaited type?
|
|
This is mostly just a documentation fix as I don't think stability
attributes have any effect on macros.
|
|
Add examples for `std::thread::Thread::name`.
None
|
|
Document `CStr::as_ptr` dangers.
r? @steveklabnik
Hi! I've tried to document `CString::new("hello").unwrap().as_ptr()` footgun. Related [RFC] and the original [discussion].
[RFC]: https://github.com/rust-lang/rfcs/pull/1642
[discussion]: https://users.rust-lang.org/t/you-should-stop-telling-people-that-safe-rust-is-always-safe/6094
|
|
|
|
|
|
Add short summaries to btree modules
Also improve hash_map and hash_set module short summaries.
These are missing from [here](https://doc.rust-lang.org/nightly/std/collections/#modules).
r? @steveklabnik
|