| Age | Commit message (Collapse) | Author | Lines |
|
|
|
rustc/rustdoc: Perform name resolver cleanups enabled by #94857
Unblocks https://github.com/rust-lang/rust/pull/105462.
r? `@oli-obk`
|
|
We use more specific `mk_*` functions in most places, might as well use
them as much as possible.
|
|
|
|
rustdoc: Remove cache for preprocessed markdown links
It's quite possible that it's no longer useful after https://github.com/rust-lang/rust/pull/94857 is merged.
|
|
|
|
rustdoc: Don't resolve link to field on different variant
Fix #107903
This also gives a more specific diagnostic when the enum has any fields
|
|
|
|
This commit implements MCP https://github.com/rust-lang/compiler-team/issues/584
It also removes code that is no longer used, and that includes code cloning resolver, so issue #83761 is fixed.
|
|
r=notriddle,petrochenkov
Fix handling of items inside a `doc(hidden)` block
Fixes #106373.
cc `@aDotInTheVoid`
r? `@notriddle`
|
|
|
|
|
|
|
|
rustdoc: Collect "rustdoc-reachable" items during early doc link resolution
This pass only needs to know about visibilities, attributes and reexports, so it can be run early, similarly to `compute_effective_visibilities` in rustc.
Results of this pass can be used to prune the list of extern impls early thus improving performance of https://github.com/rust-lang/rust/pull/94857.
|
|
Use `LocalDefId`s instead
|
|
|
|
|
|
|
|
Not all uses are converted, a few cases iterating through maps/sets and requiring nontrivial changes are kept.
|
|
Switch to `EarlyBinder` for `const_param_default` and `impl_trait_ref` queries
Part of the work to close #105779 and implement https://github.com/rust-lang/types-team/issues/78.
Several queries `X` have a `bound_X` variant that wraps the output in `EarlyBinder`. This PR adds `EarlyBinder` to the return type of `const_param_default` and `impl_trait_ref`, and removes their `bound_X` variants.
r? `@lcnr`
|
|
|
|
bound_impl_trait_ref query; add EarlyBinder to impl_trait_ref in metadata
|
|
|
|
Remove dead code in rustdoc stripper
No changes when this code is removed.
cc `@aDotInTheVoid`
r? `@notriddle`
|
|
Remove redundant session field
There was already a session available in the resolver, so we access that session.
|
|
|
|
|
|
|
|
Improve fluent error messages
These have been really frustrating me while migrating diagnostics.
|
|
|
|
Closes #106379
|
|
|
|
|
|
|
|
errors before this pass
|
|
r=GuillaumeGomez,jyn514,Manishearth
Consolidate rustdoc's lint passes into a single pass
This should improve performance and simplify the code.
r? `@GuillaumeGomez`
|
|
|
|
This should improve performance and simplify the code.
|
|
Record `LocalDefId` in HIR nodes instead of a side table
This is part of an attempt to remove the `HirId -> LocalDefId` table from HIR.
This attempt is a prerequisite to creation of `LocalDefId` after HIR lowering (https://github.com/rust-lang/rust/pull/96840), by controlling how `def_id` information is accessed.
This first part adds the information to HIR nodes themselves instead of a table.
The second part is https://github.com/rust-lang/rust/pull/103902
The third part will be to make `hir::Visitor::visit_fn` take a `LocalDefId` as last parameter.
The fourth part will be to completely remove the side table.
|
|
|
|
|
|
|
|
|
|
|
|
rustdoc: Simplify modifications of effective visibility table
It is now obvious that rustdoc only calls `set_access_level` with foreign def ids and `AccessLevel::Public`.
The second commit makes one more step and separates effective visibilities coming from rustc from similar data collected by rustdoc for extern `DefId`s.
The original table is no longer modified and now only contains local def ids as populated by rustc.
cc https://github.com/rust-lang/rust/pull/102026 `@Bryanskiy`
|
|
rustdoc: add missing URL redirect
https://github.com/rust-lang/rust/pull/94753 missed some redirect settings, and one of the missing URL shows up in an error message. This PR adds those redirects.
|
|
rustdoc for external def-ids
|
|
|
|
|
|
privacy: Rename "accessibility levels" to "effective visibilities"
And a couple of other naming and comment tweaks.
Related to https://github.com/rust-lang/rust/issues/48054
For `enum Level` I initially used naming `enum EffectiveVisibilityLevel`, but it was too long and inconvenient because it's used pretty often.
So I shortened it to just `Level`, if it needs to be used from some context where this name would be ambiguous, then it can be imported with renaming like `use rustc_middle::privacy::Level as EffVisLevel` or something.
|