| Age | Commit message (Collapse) | Author | Lines |
|
Update documentation for fill_buf in std::io::BufRead
Brings the documentation in line with the BufReader implementation.
Fixes #48022.
This is my first PR, and I think the `E-easy` label is very cool, as so is the practice of describing the fix but leaving it for someone else; it really makes it a lot less intimidating to get started with something!
|
|
r=Mark-Simulacrum,QuietMisdreavus
Trait impl show docs
Fixes #51834.
<img width="1440" alt="screen shot 2018-06-29 at 00 14 33" src="https://user-images.githubusercontent.com/3050060/42063323-6e6e8cc8-7b31-11e8-88ef-4dd2229df76c.png">
(You can see both commit changes in the screenshot 😄)
r? @QuietMisdreavus
|
|
Brings the documentation in line with the BufReader implementation.
Fixes #48022.
|
|
Cross reference io::copy and fs::copy in docs.
Fixes https://github.com/rust-lang/rust/issues/52524.
|
|
|
|
|
|
|
|
|
|
Fixes https://github.com/rust-lang/rust/issues/52524.
|
|
state of the mutex
|
|
|
|
|
|
|
|
|
|
|
|
Rollup of bare_trait_objects PRs
All deny attributes were moved into bootstrap so they can be disabled with a line of config.
Warnings for external tools are allowed and it's up to the tool's maintainer to keep it warnings free.
r? @Mark-Simulacrum
cc @ljedrz @kennytm
|
|
|
|
'ljedrz/dyn_libterm' into dyn-rollup
|
|
Reduce misconceptions about Cursor being more general than it really is.
Fixes: #52470
|
|
|
|
|
|
|
|
The original example didn't check the return value of `write()`, didn't
flush the writer, and didn't properly demonstrate the buffering.
Fixes #51621.
|
|
Make Stdio handle UnwindSafe
Closes #51863
This is my first compiler PR. Thanks Niko for the mentor help!
r? @nikomatsakis
|
|
Implement always-fallible TryFrom for usize/isize conversions that are infallible on some platforms
This reverts commit 837d6c70233715a0ae8e15c703d40e3046a2f36a "Remove TryFrom impls that might become conditionally-infallible with a portability lint".
This fixes #49415 by adding (restoring) missing `TryFrom` impls for integer conversions to or from `usize` or `isize`, by making them always fallible at the type system level (that is, with `Error=TryFromIntError`) even though they happen to be infallible on some platforms (for some values of `size_of::<usize>()`).
They had been removed to allow the possibility to conditionally having some of them be infallible `From` impls instead, depending on the platforms, and have the [portability lint](https://github.com/rust-lang/rfcs/pull/1868) warn when they are used in code that is not already opting into non-portability. For example `#[allow(some_lint)] usize::from(x: u64)` would be valid on code that only targets 64-bit platforms.
This PR gives up on this possiblity for two reasons:
* Based on discussion with @aturon, it seems that the portability lint is not happening any time soon. It’s better to have the conversions be available *at all* than keep blocking them for so long. Portability-lint-gated platform-specific APIs can always be added separately later.
* For code that is fine with fallibility, the alternative would force it to opt into "non-portability" even though there would be no real portability issue.
|
|
|
|
|
|
Signed-off-by: NODA, Kai <nodakai@gmail.com>
|
|
a portability lint"
This reverts commit 837d6c70233715a0ae8e15c703d40e3046a2f36a.
Fixes https://github.com/rust-lang/rust/issues/49415
|
|
Per FCP:
* https://github.com/rust-lang/rust/issues/27802#issuecomment-377537778
* https://github.com/rust-lang/rust/issues/33906#issuecomment-377534308
|
|
Fixes #42781
|
|
Add some performance guidance to std::fs and std::io docs
Adds more documentation about performance to various "read" functions in `fs` and `io`, and to `BufReader`/`BufWriter`, with the goal of helping developers choose the best option for a given task.
|
|
|
|
|
|
|
|
r=GuillaumeGomez
Remove hidden `foo` functions from doc examples; use `Termination` trait.
Fixes https://github.com/rust-lang/rust/issues/49233.
Easier to review with the white-space ignoring `?w=1` feature: https://github.com/rust-lang/rust/pull/49357/files?w=1
|
|
Fixes https://github.com/rust-lang/rust/issues/49233.
|
|
portability lint
https://github.com/rust-lang/rust/pull/49305#issuecomment-376293243
|
|
This subsumes the need for an explicit is_empty function, and provides
access to the buffered data itself which has been requested from time to
time.
|
|
|
|
|
|
|
|
|
|
fix more typos found by codespell.
|
|
|
|
Remove "empty buffer" doc in read_until
This appears copied from fill_buf, but the above paragraph already indicates that a lack of delimiter at the end is EOF.
|
|
This appears copied from fill_buf, but the above paragraph already indicates that a lack of delimiter at the end is EOF.
|
|
|
|
On MIPS, error number 98 is not EADDRINUSE (it is EPROTOTYPE). To fix the
resulting test failure this causes, use a more portable error number in
the example documentation. EINVAL shold be more reliable because it was
defined in the original Unix as 22 so hopefully most derivatives have
defined it the same way.
|
|
fix off-by-one error
Fixes https://github.com/rust-lang/rust/issues/47325.
|