-
Notifications
You must be signed in to change notification settings - Fork 12.8k
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
Use Intra-doc links for std::io::buffered #78006
Conversation
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @jyn514 (or someone else) soon. If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes. Please see the contribution instructions for more information. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for working on this :)
Looks great! r=me when CI passes (feel free to ping me tomorrow if I forget to ping bors). |
I'm guessing errors like the following here are caused by not yet having #77267 (as seen in #77875):
I made that last commit which fixes those (not sure if it's the style you'd like to see, but it works). I figured out that these errors here are because I was looking at the wrong
I was looking at
So maybe those links should link to the trait methods as they already do? Because linking them like
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
linking them like crate::net::TcpStream::write() doesn't work either
You probably need use crate::io::Write
; trait items aren't resolved unless the trait is in scope.
I'm guessing errors like the following here are caused by not yet having #77267 (as seen in #77875)
Hmm, that seems like a separate bug - these aren't re-exports but just the primitives themselves. Did this happen with --stage 0 or --stage 1? (CI runs --stage 2, doc
uses --stage 0
by default)
Is there something special I have to do to import item for use with intra-doc links? Both look to be in scope to me:
The "the builtin type These errors are all from CI. The "here" links link to CI logs. It looks to me like CI runs with |
FYI I haven't forgotten about this but I don't have time to investigate all the bugs right now. I think the way forward is to file issues for the things that seem like they should work and revert the relevant changes for now. |
@pitaj I can't reproduce this failure locally.
Do you think you could try to make an example smaller than the full standard library? Also, since this is only in the standard library, #54172 is definitely the wrong issue for this. |
@jyn514 I have been able to reproduce this in a crate by copying https://github.com/pitaj/rustdoc-78006-repro I'll work tomorrow and see if I can prune it down some more. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
r=me with nit fixed
@bors r+ rollup |
📌 Commit 8d48e3b has been approved by |
Use Intra-doc links for std::io::buffered Helps with rust-lang#75080. I used the implicit link style for intrinsics, as that was what `minnumf32` and others already had. `@rustbot` modify labels: T-doc, A-intra-doc-links r? `@jyn514`
Rollup of 15 pull requests Successful merges: - rust-lang#74979 (`#![deny(unsafe_op_in_unsafe_fn)]` in sys/hermit) - rust-lang#78006 (Use Intra-doc links for std::io::buffered) - rust-lang#78167 (Fix unreachable sub-branch detection in or-patterns) - rust-lang#78514 (Allow using 1/2/3/4 for `x.py setup` options) - rust-lang#78538 (BTreeMap: document a curious assumption in test cases) - rust-lang#78559 (Add LLVM upgrades from 7 to 10 to RELEASES.md) - rust-lang#78666 (Fix shellcheck error) - rust-lang#78705 (Print a summary of which test suite failed) - rust-lang#78726 (Add link to rust website) - rust-lang#78730 (Expand explanation of reverse_bits) - rust-lang#78760 (`deny(invalid_codeblock_attributes)` for rustc_error_codes) - rust-lang#78771 (inliner: Copy unevaluated constants only after successful inlining) - rust-lang#78794 (rustc_expand: use collect_bang helper instead of manual reimplementation) - rust-lang#78795 (The renumber pass is long gone) - rust-lang#78798 (Fixing Spelling Typos) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
Helps with #75080. I used the implicit link style for intrinsics, as that was what
minnumf32
and others already had.@rustbot modify labels: T-doc, A-intra-doc-links
r? @jyn514