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

Move to doc links inside std/time.rs #75371

Merged
merged 2 commits into from
Aug 12, 2020

Conversation

poliorcetics
Copy link
Contributor

Helps with #75080.

@rustbot modify labels: T-doc, A-intra-doc-links, T-rustdoc

@rustbot rustbot added A-intra-doc-links Area: Intra-doc links, the ability to link to items in docs by name A-docs Area: documentation for any part of the project, including the compiler, standard library, and tools T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. labels Aug 10, 2020
@rust-highfive
Copy link
Collaborator

r? @cramertj

(rust_highfive has picked a reviewer for you, use r? to override)

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Aug 10, 2020
library/std/src/time.rs Outdated Show resolved Hide resolved
@jyn514
Copy link
Member

jyn514 commented Aug 12, 2020

❤️ these sorts of PRs make me think all the time I put in was worth it :)

@bors r+ rollup

@bors
Copy link
Contributor

bors commented Aug 12, 2020

📌 Commit bd01bf9 has been approved by jyn514

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Aug 12, 2020
@@ -368,7 +361,7 @@ impl Add<Duration> for Instant {
/// This function may panic if the resulting point in time cannot be represented by the
/// underlying data structure. See [`checked_add`] for a version without panic.
///
/// [`checked_add`]: ../../std/time/struct.Instant.html#method.checked_add
/// [`checked_add`]: Instant::checked_add
Copy link
Contributor

Choose a reason for hiding this comment

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

We could also do the same trick here.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This is already being merged so I won't modify further but a follow up PR would probably be accepted without any problem. 😃

@@ -544,7 +527,7 @@ impl Add<Duration> for SystemTime {
/// This function may panic if the resulting point in time cannot be represented by the
/// underlying data structure. See [`checked_add`] for a version without panic.
///
/// [`checked_add`]: ../../std/time/struct.SystemTime.html#method.checked_add
/// [`checked_add`]: SystemTime::checked_add
Copy link
Contributor

Choose a reason for hiding this comment

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

And here, it would be clearer. Reading the code directly is way better now, also the docs will be more explicit.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Same as above

bors added a commit to rust-lang-ci/rust that referenced this pull request Aug 12, 2020
Rollup of 9 pull requests

Successful merges:

 - rust-lang#74521 (older toolchains not valid anymore)
 - rust-lang#74960 (Fix regionck failure when converting Index to IndexMut)
 - rust-lang#75234 (Update asm! documentation in unstable book)
 - rust-lang#75368 (Move to doc links inside the prelude)
 - rust-lang#75371 (Move to doc links inside std/time.rs)
 - rust-lang#75394 (Add a function to `TyCtxt` for computing an `Allocation` for a `static` item's initializer)
 - rust-lang#75395 (Switch to intra-doc links in library/std/src/os/*/fs.rs)
 - rust-lang#75422 (Accept more safety comments)
 - rust-lang#75424 (fix wrong word in documentation)

Failed merges:

r? @ghost
@bors bors merged commit 261773e into rust-lang:master Aug 12, 2020
@poliorcetics poliorcetics deleted the intra-doc-links-std-time branch August 12, 2020 06:49
@jyn514 jyn514 removed the T-rustdoc Relevant to the rustdoc team, which will review and decide on the PR/issue. label Aug 25, 2020
@cuviper cuviper added this to the 1.47.0 milestone May 2, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-docs Area: documentation for any part of the project, including the compiler, standard library, and tools A-intra-doc-links Area: Intra-doc links, the ability to link to items in docs by name S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants