| Age | Commit message (Collapse) | Author | Lines |
|
|
|
Rename methods section
Fixes https://github.com/rust-lang/rust/issues/70475.
It renames the section [methods](https://doc.rust-lang.org/nightly/std/string/struct.String.html#methods) into "Implementations". However, I didn't not update the title in the sidebar considering that it only lists methods under (even though I updated the link of the "methods" to make it point to the "implementations" section.
r? @kinnison
cc @rust-lang/rustdoc
|
|
|
|
|
|
|
|
|
|
Local items defined in external macros shouldn't generate rendered source files and should link to the external crate's docs instead.
|
|
They used to be covered by `optin_builtin_traits` but negative impls
are now applicable to all traits, not just auto traits.
This also adds docs in the unstable book for the current state of auto traits.
|
|
r=ehuss,aleksator,ollie27
Stabilize --crate-version option in rustdoc
I don't see any reason to not stabilize it anymore, so let's go!
cc @kinnison @ehuss
r? @ollie27
|
|
|
|
|
|
Cleanup `rmeta::MacroDef`
Avoid using rountrip parsing in the encoder and in `fn load_macro_untracked`.
The main reason I was interested in this was to remove `rustc_parse` as a dependency of `rustc_metadata` but it seems like this had other benefits as well.
Fixes #49511.
r? @eddyb
cc @matthewjasper @estebank @petrochenkov
|
|
|
|
Remove spotlight
I had a few comments saying that this feature was at best misunderstood or not even used so I decided to organize a poll about on [twitter](https://twitter.com/imperioworld_/status/1232769353503956994). After 87 votes, the result is very clear: it's not useful. Considering the amount of code we have just to run it, I think it's definitely worth it to remove it.
r? @kinnison
cc @ollie27
|
|
rustdoc: HTML escape crate version
As `--crate-version` accepts arbitrary strings they need to be escaped.
r? @GuillaumeGomez
|
|
As `--crate-version` accepts arbitrary strings they need to be escaped.
|
|
|
|
|
|
|
|
Fixes #68690
When we generate the proc macro harness, we now explicitly recorder the
order in which we generate entries. We then use this ordering data to
deserialize the correct proc-macro-data from the crate metadata.
|
|
r=LukasKalbertodt
Move numeric consts to associated consts step1
A subset of #67913. Implements the first step of RFC https://github.com/rust-lang/rfcs/pull/2700
This PR adds the new constants as unstable constants and defines the old ones in terms of the new ones. Then fix a tiny bit of code that started having naming collisions because of the new assoc consts.
Removed a test that did not seem relevant any longer. Since doing just `u8::MIN` should now indeed be valid.
|
|
* Generate links to the primitive type docs for re-exports.
* Don't ICE on cross crate primitive type re-exports.
* Make primitive type re-exports show up cross crate.
|
|
|
|
Remove usage of global variable "inlined_types"
r? @pietroalbini
|
|
|
|
|
|
r=GuillaumeGomez
rustdoc: Catch fatal errors when syntax highlighting
For some errors the lexer will unwind so we need to handle that in addition to handling `token::Unknown`.
Fixes #56885
r? @GuillaumeGomez
|
|
Prevent urls in headings
Fixes #68215.
cc @pietroalbini @ollie27
r? @kinnison
|
|
Fix deref impl typedef
Fixes #35295.
r? @kinnison
|
|
For some errors the lexer will unwind so we need to handle that in addition to handling `token::Unknown`.
|
|
|
|
r=GuillaumeGomez
rustdoc: HTML escape codeblocks which fail syntax highlighting
r? @GuillaumeGomez
|
|
|
|
|
|
|
|
|
|
|
|
|
|
rustdoc: Remove more `#[doc(cfg(..))]` duplicates
This is a follow up to #66959.
r? @GuillaumeGomez
|
|
Distinguish between private items and hidden items in rustdoc
I believe rustdoc should not be conflating private items (visibility lower than `pub`) and hidden items (attribute `doc(hidden)`). This matters now that Cargo is passing --document-private-items by default for bin crates. In bin crates that rely on macros, intentionally hidden implementation details of the macros can overwhelm the actual useful internal API that one would want to document.
This PR restores the strip-hidden pass when documenting private items, and introduces a separate unstable --document-hidden-items option to skip the strip-hidden pass. The two options are orthogonal to one another.
Fixes #67851. Closes #60884.
|
|
rustdoc: HTML escape const values
r? @GuillaumeGomez
|
|
Omit underscore constants from rustdoc
Underscore constants from https://github.com/rust-lang/rfcs/pull/2526 / https://github.com/rust-lang/rust/issues/54912 do not correspond to a nameable item and so are never useful in documentation.
<br>
#### Before:
> <img src="https://user-images.githubusercontent.com/1940490/71771409-0427cc80-2eef-11ea-8b7d-d9c74a873e7e.png" width="60%">
#### After:
> Not that.
|
|
|
|
|
|
|
|
I believe rustdoc should not be conflating private items (visibility
lower than `pub`) and hidden items (attribute `doc(hidden)`). This
matters now that Cargo is passing --document-private-items by default
for bin crates. In bin crates that rely on macros, intentionally hidden
implementation details of the macros can overwhelm the actual useful
internal API that one would want to document.
This PR restores the strip-hidden pass when documenting private items,
and introduces a separate unstable --document-hidden-items option to
skip the strip-hidden pass. The two options are orthogonal to one
another.
|
|
`make_test` is also called when parsing codeblocks for the playground links so it should handle unwinds from the parser internally.
|
|
|
|
Remove mem::uninitalized from tests
This purges uses of uninitialized where possible from test cases. Some
are merely moved over to the equally bad pattern of
MaybeUninit::uninit().assume_init() but with an annotation that this is
"the best we can do".
Fixes #62397
|
|
This purges uses of uninitialized where possible from test cases. Some
are merely moved over to the equally bad pattern of
MaybeUninit::uninit().assume_init() but with an annotation that this is
"the best we can do".
|