about summary refs log tree commit diff
path: root/compiler/rustc_const_eval/src/check_consts/check.rs
diff options
context:
space:
mode:
Diffstat (limited to 'compiler/rustc_const_eval/src/check_consts/check.rs')
-rw-r--r--compiler/rustc_const_eval/src/check_consts/check.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_const_eval/src/check_consts/check.rs b/compiler/rustc_const_eval/src/check_consts/check.rs
index 69637cadcc9..44e5d1d5ee7 100644
--- a/compiler/rustc_const_eval/src/check_consts/check.rs
+++ b/compiler/rustc_const_eval/src/check_consts/check.rs
@@ -784,7 +784,7 @@ impl<'tcx> Visitor<'tcx> for Checker<'_, 'tcx> {
                     self.revalidate_conditional_constness(callee, fn_args, *fn_span);
 
                 // Attempting to call a trait method?
-                if let Some(trait_did) = tcx.trait_of_item(callee) {
+                if let Some(trait_did) = tcx.trait_of_assoc(callee) {
                     // We can't determine the actual callee here, so we have to do different checks
                     // than usual.