rust/compiler/rustc_ast_passes/src
Matthias Krüger 110c3df7fd
Rollup merge of #126013 - nnethercote:unreachable_pub, r=Urgau
Add `#[warn(unreachable_pub)]` to a bunch of compiler crates

By default `unreachable_pub` identifies things that need not be `pub` and tells you to make them `pub(crate)`. But sometimes those things don't need any kind of visibility. So they way I did these was to remove the visibility entirely for each thing the lint identifies, and then add `pub(crate)` back in everywhere the compiler said it was necessary. (Or occasionally `pub(super)` when context suggested that was appropriate.) Tedious, but results in more `pub` removal.

There are plenty more crates to do but this seems like enough for a first PR.

r? `@compiler-errors`
2024-08-27 00:41:57 +02:00
..
ast_validation.rs Rollup merge of #129345 - compiler-errors:scratch4, r=jieyouxu 2024-08-21 18:15:06 +02:00
errors.rs Rollup merge of #126013 - nnethercote:unreachable_pub, r=Urgau 2024-08-27 00:41:57 +02:00
feature_gate.rs Auto merge of #127672 - compiler-errors:precise-capturing, r=spastorino 2024-08-20 10:42:55 +00:00
lib.rs Add warn(unreachable_pub) to rustc_ast_passes. 2024-08-16 08:46:41 +10:00
node_count.rs Rename HIR TypeBinding to AssocItemConstraint and related cleanup 2024-05-30 22:52:33 +02:00
show_span.rs Use a dedicated type instead of a reference for the diagnostic context 2024-06-18 15:42:11 +00:00