cg_llvm: Reduce the visibility of types, modules and using declarations in rustc_codegen_llvm.#137247
Conversation
|
I've been thinking about how to deal with the enums that have more than 1-2 unused variants, especially the ones where almost all variants are unused. Putting So for those enums, I think it's going to be better to just put That's a bit of a shame, but it's still an improvement over the status quo of everything being |
|
Specifically, I'm proposing that these enums should have
|
ecb9173 to
f47f772
Compare
Done |
|
Adding reasons for the |
|
@bors r+ |
cg_llvm: Reduce the visibility of types, modules and using declarations in `rustc_codegen_llvm`. Final part of rust-lang#135502 Reduces the visibility of types, modules and using declarations in the `rustc_codegen_llvm` to private or `pub(crate)` where possible, and marks unused fields and enum entries with `#[expect(dead_code)]`. r? `@Zalathar`
|
Ah, this collided with some more |
a5d4c5c to
5bf2edb
Compare
Updated. |
|
Hmm, I think I lost track of this because more conflicts occurred shortly after the last rebase; it seems to need another rebase. |
|
@rustbot author |
|
@rustbot ready |
|
Oh, could you please reapply the |
Sorry about that: fixed. |
|
Reapplied a clearer commit name, and fixed one expect reason (diff). |
|
@bors r+ |
…iaskrgr Rollup of 8 pull requests Successful merges: - rust-lang#135745 (Recognise new IPv6 non-global range from IETF RFC 9602) - rust-lang#137247 (cg_llvm: Reduce the visibility of types, modules and using declarations in `rustc_codegen_llvm`.) - rust-lang#138317 (privacy: Visit types and traits in impls in type privacy lints) - rust-lang#138581 (Abort in deadlock handler if we fail to get a query map) - rust-lang#138776 (coverage: Separate span-extraction from unexpansion) - rust-lang#138886 (Fix autofix for `self` and `self as …` in `unused_imports` lint) - rust-lang#138924 (Reduce `kw::Empty` usage, part 3) - rust-lang#138929 (Visitors track whether an assoc item is in a trait impl or an inherent impl) r? `@ghost` `@rustbot` modify labels: rollup
Rollup merge of rust-lang#137247 - dpaoliello:cleanllvm, r=Zalathar cg_llvm: Reduce the visibility of types, modules and using declarations in `rustc_codegen_llvm`. Final part of rust-lang#135502 Reduces the visibility of types, modules and using declarations in the `rustc_codegen_llvm` to private or `pub(crate)` where possible, and marks unused fields and enum entries with `#[expect(dead_code)]`. r? Zalathar
Final part of #135502
Reduces the visibility of types, modules and using declarations in the
rustc_codegen_llvmto private orpub(crate)where possible, and marks unused fields and enum entries with#[expect(dead_code)].r? Zalathar