Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: replace method links with intra-links #2540

Merged
merged 2 commits into from May 30, 2020
Merged

docs: replace method links with intra-links #2540

merged 2 commits into from May 30, 2020

Conversation

ghost
Copy link

@ghost ghost commented May 16, 2020

Motivation

Make doc's links more resistant.

Solution

Delagates doc's links resolution to rustdoc.

Refs: #1473

@ghost
Copy link
Author

ghost commented May 16, 2020

Blocked by rust-lang/rust#71289

Copy link
Contributor

@Darksonn Darksonn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you. You can just comment when the PR is ready to have the CI doc test re-run.

tokio/src/io/registration.rs Outdated Show resolved Hide resolved
@Darksonn Darksonn added A-tokio Area: The main tokio crate C-maintenance Category: PRs that clean code up or issues documenting cleanup. T-docs Topic: documentation labels May 16, 2020
tokio/src/net/udp/split.rs Outdated Show resolved Hide resolved
tokio/src/net/udp/split.rs Outdated Show resolved Hide resolved
@ghost ghost marked this pull request as ready for review May 24, 2020 21:26
@ghost
Copy link
Author

ghost commented May 24, 2020

It's ready for review @Darksonn
Take a look at changes related to register.
It looks like doc leftovers after API changes? Any suggestions are welcome.

tokio/src/io/registration.rs Outdated Show resolved Hide resolved
tokio/src/io/registration.rs Outdated Show resolved Hide resolved
@ghost
Copy link
Author

ghost commented May 24, 2020

No idea why it fails - I'll check it later
Anyway works for me

[23:43:37] xliiv@alef /home/xliiv/workspace/tokio (0)
> env RUSTDOCFLAGS="--cfg docsrs" cargo +nightly doc --all-features
    Finished dev [unoptimized + debuginfo] target(s) in 0.09s
[23:43:39] xliiv@alef /home/xliiv/workspace/tokio (0)
> rustc +nightly --version
rustc 1.45.0-nightly (8970e8bcf 2020-05-23)
[23:43:45] xliiv@alef /home/xliiv/workspace/tokio (0)
> git show --summary
commit 03510730bc563091b83ea3aabb75146df04d1b6f (HEAD -> 1473-fix-links, xliiv/1473-fix-links)
Author: Tymoteusz Jankowski <tymoteusz.jankowski@gmail.com>
Date:   Fri May 22 22:07:20 2020 +0200

    docs: replace method links with intra-links

@taiki-e
Copy link
Member

taiki-e commented May 24, 2020

CI failure is due to our CI using old nightly rustc:

nightly: nightly-2020-01-25

@ghost
Copy link
Author

ghost commented May 25, 2020

@taiki-e is there an upgrade policy? can i upgrade?
and thanks for finding it

@Darksonn
Copy link
Contributor

I don't think there's an official policy, but we should probably verify that docs.rs uses a similarly new nightly to compile their docs. If they are, I think it is fine to go ahead an update it.

@ghost
Copy link
Author

ghost commented May 25, 2020

@Darksonn it should be ok, according to this

The current version of the Rust compiler in use is rustc 1.45.0-nightly (46e85b432 2020-05-24)

from https://docs.rs/about

@ghost
Copy link
Author

ghost commented May 25, 2020

Just upgraded, let's see if it works now..

BTW I've made it 2 commits on purpose (one extra for the upgrade). Let me know if it's OK.

@Darksonn
Copy link
Contributor

It looks good. I commented on the registration thing, and it appears to be rather easy to fix. Once that's changed, we can merge it.

@ghost
Copy link
Author

ghost commented May 30, 2020

@Darksonn, it seems rustfmt got fixed, so I've updated the nightly version to the working one.

see
https://rust-lang-nursery.github.io/rust-toolstate/

@Darksonn Darksonn merged commit f2f30d4 into tokio-rs:master May 30, 2020
jensim pushed a commit to jensim/tokio that referenced this pull request Jun 7, 2020
hawkw added a commit that referenced this pull request Jul 20, 2020
- docs: misc improvements (#2572, #2658, #2663, #2656, #2647, #2630, #2487, #2621,
  #2624, #2600, #2623, #2622, #2577, #2569, #2589, #2575, #2540, #2564, #2567,
  #2520, #2521, #2572, #2493)
- rt: allow calls to `block_on` inside calls to `block_in_place` that are
  themselves inside `block_on` (#2645)
- net: fix non-portable behavior when dropping `TcpStream` `OwnedWriteHalf` (#2597)
- io: improve stack usage by allocating large buffers on directly on the heap
  (#2634)
- io: fix unsound pin projection in `AsyncReadExt::read_buf` and
  `AsyncWriteExt::write_buf` (#2612)
- io: fix unnecessary zeroing for `AsyncRead` implementors (#2525)
- io: Fix `BufReader` not correctly forwarding `poll_write_buf` (#2654)

- coop: returning `Poll::Pending` no longer decrements the task budget (#2549)

- io: little-endian variants of `AsyncReadExt` and `AsyncWriteExt` methods
  (#1915)
- io: fix panic in `AsyncReadExt::read_line` (#2541)
- task: add [`tracing`] instrumentation to spawned tasks (#2655)
- sync: allow unsized types in `Mutex` and `RwLock` (via `default` constructors)
  (#2615)
- net: add `ToSocketAddrs` implementation for `&[SocketAddr]` (#2604)
- fs: add `OpenOptionsExt` for `OpenOptions` (#2515)
- fs: add `DirBuilder` (#2524)

[`tracing`]: https://crates.io/crates/tracing

Signed-off-by: Eliza Weisman <eliza@buoyant.io>
hawkw added a commit that referenced this pull request Jul 22, 2020
# 0.2.22 (July 2!, 2020)

### Fixes
- docs: misc improvements (#2572, #2658, #2663, #2656, #2647, #2630, #2487, #2621,
  #2624, #2600, #2623, #2622, #2577, #2569, #2589, #2575, #2540, #2564, #2567,
  #2520, #2521, #2493)
- rt: allow calls to `block_on` inside calls to `block_in_place` that are
  themselves inside `block_on` (#2645)
- net: fix non-portable behavior when dropping `TcpStream` `OwnedWriteHalf` (#2597)
- io: improve stack usage by allocating large buffers on directly on the heap
  (#2634)
- io: fix unsound pin projection in `AsyncReadExt::read_buf` and
  `AsyncWriteExt::write_buf` (#2612)
- io: fix unnecessary zeroing for `AsyncRead` implementors (#2525)
- io: Fix `BufReader` not correctly forwarding `poll_write_buf` (#2654)
- io: fix panic in `AsyncReadExt::read_line` (#2541)

### Changes
- coop: returning `Poll::Pending` no longer decrements the task budget (#2549)

### Added
- io: little-endian variants of `AsyncReadExt` and `AsyncWriteExt` methods
  (#1915)
- task: add [`tracing`] instrumentation to spawned tasks (#2655)
- sync: allow unsized types in `Mutex` and `RwLock` (via `default` constructors)
  (#2615)
- net: add `ToSocketAddrs` implementation for `&[SocketAddr]` (#2604)
- fs: add `OpenOptionsExt` for `OpenOptions` (#2515)
- fs: add `DirBuilder` (#2524)

[`tracing`]: https://crates.io/crates/tracing

Signed-off-by: Eliza Weisman <eliza@buoyant.io>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-tokio Area: The main tokio crate C-maintenance Category: PRs that clean code up or issues documenting cleanup. T-docs Topic: documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants