about summary refs log tree commit diff
path: root/compiler/rustc_codegen_llvm/src/lib.rs
diff options
context:
space:
mode:
authorMatthias Krüger <476013+matthiaskrgr@users.noreply.github.com>2025-03-25 18:09:03 +0100
committerGitHub <noreply@github.com>2025-03-25 18:09:03 +0100
commitb66e9320c53a2fddc2c493cd6ffb772bef206977 (patch)
tree390eb7b50c760f279a744a041dce77ec810b1a14 /compiler/rustc_codegen_llvm/src/lib.rs
parent5f6c1a9f573b2aab044c856589c9d9de3c821af3 (diff)
parent79b9664091e90c08a7abeab2bbc4a941bcdc3863 (diff)
downloadrust-b66e9320c53a2fddc2c493cd6ffb772bef206977.tar.gz
rust-b66e9320c53a2fddc2c493cd6ffb772bef206977.zip
Rollup merge of #137247 - dpaoliello:cleanllvm, r=Zalathar
cg_llvm: Reduce the visibility of types, modules and using declarations in `rustc_codegen_llvm`.

Final part of #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
Diffstat (limited to 'compiler/rustc_codegen_llvm/src/lib.rs')
-rw-r--r--compiler/rustc_codegen_llvm/src/lib.rs6
1 files changed, 2 insertions, 4 deletions
diff --git a/compiler/rustc_codegen_llvm/src/lib.rs b/compiler/rustc_codegen_llvm/src/lib.rs
index f622646a5d9..425381b0ffa 100644
--- a/compiler/rustc_codegen_llvm/src/lib.rs
+++ b/compiler/rustc_codegen_llvm/src/lib.rs
@@ -29,7 +29,7 @@ use back::owned_target_machine::OwnedTargetMachine;
 use back::write::{create_informational_target_machine, create_target_machine};
 use context::SimpleCx;
 use errors::{AutoDiffWithoutLTO, ParseTargetMachineConfig};
-pub(crate) use llvm_util::target_features_cfg;
+use llvm_util::target_features_cfg;
 use rustc_ast::expand::allocator::AllocatorKind;
 use rustc_ast::expand::autodiff_attrs::AutoDiffItem;
 use rustc_codegen_ssa::back::lto::{LtoModuleCodegen, SerializedModule, ThinModule};
@@ -71,9 +71,7 @@ mod debuginfo;
 mod declare;
 mod errors;
 mod intrinsic;
-// FIXME(Zalathar): Fix all the unreachable-pub warnings that would occur if
-// this isn't pub, then make it not pub.
-pub mod llvm;
+mod llvm;
 mod llvm_util;
 mod mono_item;
 mod type_;