| Age | Commit message (Collapse) | Author | Lines |
|
|
|
|
|
This gets rid of a bunch of `unwrap()`s and makes it a little more clear
what's going on.
Originally I wanted to make `fold_item` non-nullable too, which would
have been a lot nicer to work with, but unfortunately `stripper` does
actually return `None` in some places. I might make a follow-up moving
stripper to be special and not a pass so that passes can be
non-nullable.
|
|
This gives warnings about dead code.
|
|
This removes the unnecessary `DocFragmentKind::Divider` in favor of just
using the logic I actually want in `collapse_docs`.
|
|
This makes the code a lot easier to work with. It also makes it easier
to add new fields without updating each variant and `match`
individually.
- Name the `Kind` variant after `DocFragmentKind` from `collapse_docs`
- Remove unneeded impls
|
|
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.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Partial implementation of https://github.com/rust-lang/rfcs/pull/1990
(needs error reporting work)
cc #44732
|
|
|
|
Now that each pass has its own module, there's not much of a reason to
keep these structs within the functions.
|
|
|