| Age | Commit message (Collapse) | Author | Lines |
|
|
|
r=petrochenkov
refactor: create multiple HIR items for imports
When lowering `use` statements into HIR, they get a `Def` of the thing they're pointing at. This is great for things that need to know what was just pulled into scope. However, this is a bit misleading, because a `use` statement can pull things from multiple namespaces if their names collide. This is a problem for rustdoc, because if there are a module and a function with the same name (for example) then it will only document the module import, because that's that the lowered `use` statement points to.
The current version of this PR does the following:
* Whenever the resolver comes across a `use` statement, it loads the definitions into a new `import_map` instead of the existing `def_map`. This keeps the resolutions per-namespace so that all the target definitions are available.
* When lowering `use` statements, it looks up the resolutions in the `import_map` and creates multiple `Item`s if there is more than one resolution.
* To ensure the `NodeId`s are properly tracked in the lowered module, they need to be created in the AST, and pulled out as needed if multiple resolutions are available.
Fixes https://github.com/rust-lang/rust/issues/34843
|
|
Add lint for intra link resolution failure
This PR is almost done, just remains this note:
```
note: requested on the command line with `-W intra-link-resolution-failure`
```
I have no idea why my lint is considered as being passed through command line and wasn't able to find where it was set. If anyone has an idea, it'd be very helpful!
cc @QuietMisdreavus
|
|
|
|
|
|
|
|
|
|
r=QuietMisdreavus
Fix crate-name option in rustdoc
Fixes #51229.
r? @QuietMisdreavus
|
|
|
|
|
|
|
|
|
|
r=QuietMisdreavus
Add attributes for trait and methods as well
Fixes #48485.
r? @QuietMisdreavus
|
|
|
|
This avoids a full compiler build in order to build and/or run tests for
rustdoc.
|
|
rustdoc: hide macro export statements from docs
As mentioned in https://github.com/rust-lang/rust/issues/50647, rustdoc now prints both the import statement and the macro itself when re-exporting macros. This is a stopgap solution to clean up the std docs and get something small backported into beta.
What this does: When rustdoc finds an export statement for a macro, instead of printing the export and bailing, now it will instead hide the export and bail. Until we can solve https://github.com/rust-lang/rust/issues/34843 or have a better way to find the attributes on an export statement when inlining macros, this will at least match the current behavior and clean up the re-export statements from the docs.
|
|
|
|
|
|
add auto-impl for primitive type
Part of #50431.
I have no clue how to test this though with the rustdoc test suite...
r? @QuietMisdreavus
|
|
|
|
|
|
|
|
Prevent infinite recursion of modules
Fixes #50196.
r? @QuietMisdreavus
|
|
|
|
|
|
|
|
It's subsumed by `feature(use_extern_macros)` and `pub use`
|
|
|
|
|
|
rustdoc: Don't include private paths in all.html
For example the `std` [`all.html`](https://doc.rust-lang.org/nightly/std/all.html) includes references to the `coresimd` module which is a private implementation detail.
r? @GuillaumeGomez
|
|
|
|
|
|
|
|
Add page to list all crate's items
r? @QuietMisdreavus
|
|
GuillaumeGomez:remove-unneeded-trait-implementations-title, r=QuietMisdreavus
Remove unneeded trait implementations titles
r? @QuietMisdreavus
|
|
GuillaumeGomez:fix-intra-link-trait-provided-method, r=QuietMisdreavus
Fix url for intra link provided method
Fixes #49582.
r? @QuietMisdreavus
|
|
r=GuillaumeGomez
Add test for rustdoc ignore test
This will check for regression on issue #32556
|
|
Add support for variant and types fields for intra links
Part of #43466.
r? @QuietMisdreavus
|
|
r=QuietMisdreavus,GuillaumeGomez
Handle future deprecation annotations
This adds special handling to the `since` parameter of the `deprecated` attribute: in particular, if the `since` version exceeds the version of the compiler, the deprecation notice will not be printed; but a note is added to the documentation stating that the item will be deprecated in a later version.
(I've used `since` for this, rather than adding a new attribute, because it's more seamless and, I feel, intuitive. Plus it involves less code churn.)


This is a prerequisite for doing things renaming methods in the standard library (e.g. #30459). Resolves #30785.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
This will check for regression on issue #32556
|
|
Add primitive intra-links
Part of #43466.
r? @QuietMisdreavus
|
|
|
|
|
|
|