rustdoc: Refractor clean_ty_generics by aDotInTheVoid · Pull Request #142275 · rust-lang/rust (original) (raw)
Refactoring towards #142226
The old clean_ty_generics was almost always called with the same args, so rename it to clean_ty_generics_inner, and add a new wrapper that generates those args from a DefId. Having this be the main entrypoint to clean_ty_generics should make it easier to start calling inferred_outlives_of #142264 (comment) (and is more readable even if we don't)
Also, replaces all calls in rustdoc to tcx.predicates_of to tcx.explicit_predicates_of, which lets us remove filter_non_trait_generics
r? @fmease