summary refs log tree commit diff
path: root/src/librustdoc/clean/inline.rs
AgeCommit message (Collapse)AuthorLines
2022-08-08rustdoc: do not mark the contents of a skipped module as inlinedMichael Howell-5/+32
2022-08-02Rollup merge of #100057 - GuillaumeGomez:rm-more-clean-impl, r=Dylan-DPCMatthias Krüger-4/+4
Remove more Clean trait implementations Follow-up of https://github.com/rust-lang/rust/pull/99638. r? ``@notriddle``
2022-08-02Rollup merge of #100005 - GuillaumeGomez:cleanup-ast-attr-clean, r=notriddleMatthias Krüger-3/+3
Remove Clean trait for ast::Attribute and improve Attributes::from_ast I prefer to keep this commit on its own for this PR because I'm changing a bit more things than expected originally: I split `Attributes::from_ast` into two because there is only one location making use of its second parameter. Follow-up of https://github.com/rust-lang/rust/pull/99638. r? `@notriddle`
2022-08-02Remove Clean trait implementation for ast::Attribute and cleanup ↵Guillaume Gomez-3/+3
Attributes::from_ast function by splitting it in two
2022-08-02Remove Clean trait implementation for ty::TraitRefGuillaume Gomez-4/+4
2022-08-01Remove visibility from AssocItem.Camille GILLOT-1/+1
2022-07-30Remove Clean trait implementation for ty::VariantDefGuillaume Gomez-3/+3
2022-07-29Box FunctionItem, TyMethodItem, MethodItem, ForeignFunctionItemest31-2/+2
This reduces ItemKind size from 160 bytes to 112 bytes
2022-07-29Box TypedefItem, ImplItem, AssocTypeItem variants of ItemKindest31-5/+5
This reduces ItemKind size from 224 bytes to 160 bytes.
2022-07-29Remove box syntax from Box<rustdoc::clean::types::ItemKind> constructionest31-2/+2
The type has 240 bytes according to compiler internal rustdoc.
2022-07-28Remove Clean trait implementation for ty::VisibilityGuillaume Gomez-3/+4
2022-07-24Remove Clean trait implementation for FieldDefGuillaume Gomez-4/+4
2022-07-23Remove Clean trait implementation for hir::Ty and middle::TyGuillaume Gomez-7/+7
2022-07-22Make some clean::Trait fields computation on demandGuillaume Gomez-8/+1
2022-07-17rustdoc: extend `#[doc(tuple_variadic)]` to fn pointersMichael Howell-2/+2
The attribute is also renamed `fake_variadic`.
2022-07-11Remove box syntax for Box<Attributes> constructionest31-4/+10
Attributes only has 48 bytes according to compiler internal rustdoc.
2022-06-11Fix incorrectly spelled "variadic"Michael Howell-1/+1
2022-06-08rustdoc: show tuple impls as `impl Trait for (T, ...)`Michael Howell-1/+5
This commit adds a new unstable attribute, `#[doc(tuple_varadic)]`, that shows a 1-tuple as `(T, ...)` instead of just `(T,)`, and links to a section in the tuple primitive docs that talks about these.
2022-05-24Rollup merge of #97288 - compiler-errors:tcxify-rustdoc, r=Dylan-DPCDylan DPC-1/+1
Lifetime variance fixes for rustdoc #97287 migrates rustc to a `Ty` type that is invariant over its lifetime `'tcx`, so I need to fix a bunch of places that assume that `Ty<'a>` and `Ty<'b>` can be unified by shortening both to some common lifetime. This is doable, since everything is already `'tcx`, so all this PR does is be a bit more explicit that elided lifetimes are actually `'tcx`. Split out from #97287 so the rustdoc team can review independently.
2022-05-23Auto merge of #94053 - GuillaumeGomez:fields-stripped, r=notriddlebors-3/+1
rustdoc: Remove fields_stripped fields (and equivalents) Fixes #90588. r? `@camelid`
2022-05-23Auto merge of #97195 - notriddle:notriddle/cleanup, r=GuillaumeGomezbors-1/+1
rustdoc: shrink GenericArgs/PathSegment with boxed slices This PR also contains a few cleanup bits and pieces, but one of them is a broken intra-doc link, and the other is removing an unused Hash impl. The last commit is the one that matters.
2022-05-22Lifetime variance fixes for rustdocMichael Goulet-1/+1
2022-05-22Auto merge of #97177 - oli-obk:const-stability, r=davidtwcobors-2/+2
Implement proper stability check for const impl Trait, fall back to unstable const when undeclared Continuation of #93960 `@jhpratt` it looks to me like the test was simply not testing for the failure you were looking for? Your checks actually do the right thing for const traits?
2022-05-21Shrink GenericArgs/PathSegment with boxed slicesMichael Howell-1/+1
2022-05-21Remove fields_stripped fields (and equivalents)Guillaume Gomez-3/+1
2022-05-21Remove `crate` visibility modifier in libs, testsJacob Pratt-9/+9
2022-05-19Add and use stability helper methodsJacob Pratt-2/+2
This avoids an ambiguity (when reading) where `.level.is_stable()` is not immediately clear whether it is general stability or const stability.
2022-05-10update rustdoclcnr-3/+3
2022-04-16Rename `def_id` into `item_id` when the type is `ItemId` for readabilityGuillaume Gomez-1/+1
2022-04-12rustdoc: discr. required+provided assoc consts+tysLeón Orell Valerian Liehr-1/+1
2022-04-07Hide cross-crate doc-hidden assoc items in trait implsLeón Orell Valerian Liehr-4/+17
2022-03-29Remember mutability in `DefKind::Static`.Camille GILLOT-1/+1
This allows to compute the `BodyOwnerKind` from `DefKind` only, and removes a direct dependency of some MIR queries onto HIR. As a side effect, it also simplifies metadata, since we don't need 4 flavours of `EntryKind::*Static` any more.
2022-03-29Remove header field from clean::FunctionGuillaume Gomez-8/+1
2022-03-12Remove needless use of `Into`Noah Lev-2/+2
2022-03-11Improve `AdtDef` interning.Nicholas Nethercote-1/+1
This commit makes `AdtDef` use `Interned`. Much the commit is tedious changes to introduce getter functions. The interesting changes are in `compiler/rustc_middle/src/ty/adt.rs`.
2022-03-04Auto merge of #94009 - compiler-errors:gat-rustdoc, r=GuillaumeGomezbors-1/+1
Support GATs in Rustdoc Implements: 1. Rendering GATs in trait definitions and impl blocks 2. Rendering GATs in types (e.g. in the return type of a function) Fixes #92341 This is my first rustdoc PR, so I have absolutely no idea how to produce tests for this. Advice from the rustdoc team would be wonderful! I tested locally and things looked correct: ![image](https://user-images.githubusercontent.com/3674314/153988325-9732cbf3-0645-4e1a-9e64-ddfd93877b55.png)
2022-03-03make generic projection types print correctlyMichael Goulet-1/+1
2022-03-01Rollup merge of #93385 - CraftSpider:rustdoc-ty-fixes, r=camelidDylan DPC-1/+1
Rustdoc ty consistency fixes Changes to make rustdoc cleaning of ty more consistent with hir, and hopefully use it in more places. r? `@camelid`
2022-02-09Ensure that queries only return Copy types.Camille GILLOT-1/+1
2022-01-26Don't use is_local to determine function cleaning method call intentRune Tynan-1/+1
2022-01-14rustdoc: avoid many `Symbol` to `String` conversions.Nicholas Nethercote-6/+3
Particularly when constructing file paths and fully qualified paths. This avoids a lot of allocations, speeding things up on almost all examples.
2022-01-09Auto merge of #92690 - matthiaskrgr:rollup-rw0oz05, r=matthiaskrgrbors-1/+2
Rollup of 8 pull requests Successful merges: - #92055 (Add release notes for 1.58) - #92490 (Move crate drop-down to search results page) - #92510 (Don't resolve blocks in foreign functions) - #92573 (expand: Refactor InvocationCollector visitor for better code reuse) - #92608 (rustdoc: Introduce a resolver cache for sharing data between early doc link resolution and later passes) - #92657 (Implemented const casts of raw pointers) - #92671 (Make `Atomic*::from_mut` return `&mut Atomic*`) - #92673 (Remove useless collapse toggle on "all items" page) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
2022-01-09rustc_metadata: Rename `item_children(_untracked)` to ↵Vadim Petrochenkov-1/+1
`module_children(_untracked)` And `each_child_of_item` to `for_each_module_child`
2022-01-07rustdoc: Introduce a resolver cache for sharing data between early doc link ↵Vadim Petrochenkov-1/+2
resolution and later passes
2022-01-01Rustdoc: use ThinVec for GenericArgs bindingsJakub Beránek-1/+2
2021-12-23Rustdoc: use `is_doc_hidden` method on more placesJakub Beránek-4/+4
2021-12-18hir: Do not introduce dummy type names for `extern` blocks in def pathsVadim Petrochenkov-3/+3
Use a separate nameless `DefPathData` variant instead
2021-12-03Remove a Clean impl for a tuple (7)Noah Lev-3/+3
2021-12-03Remove a Clean impl for a tuple (3)Noah Lev-10/+13
2021-11-28Take a LocalDefId in expect_*item.Camille GILLOT-7/+4