Skip to content

Commit c4f6f52

Browse files
committed
Add warn(unreachable_pub) to rustc_traits.
1 parent 0fb3a50 commit c4f6f52

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed

Diff for: compiler/rustc_traits/src/codegen.rs

+1-1
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ use tracing::debug;
2121
/// obligations *could be* resolved if we wanted to.
2222
///
2323
/// This also expects that `trait_ref` is fully normalized.
24-
pub fn codegen_select_candidate<'tcx>(
24+
pub(crate) fn codegen_select_candidate<'tcx>(
2525
tcx: TyCtxt<'tcx>,
2626
(param_env, trait_ref): (ty::ParamEnv<'tcx>, ty::TraitRef<'tcx>),
2727
) -> Result<&'tcx ImplSource<'tcx, ()>, CodegenObligationError> {

Diff for: compiler/rustc_traits/src/lib.rs

+1
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
33
// tidy-alphabetical-start
44
#![recursion_limit = "256"]
5+
#![warn(unreachable_pub)]
56
// tidy-alphabetical-end
67

78
mod codegen;

0 commit comments

Comments
 (0)