From 07659996221446273065651ff9c0fcb00935eb03 Mon Sep 17 00:00:00 2001 From: kadmin Date: Fri, 30 Jul 2021 08:56:45 +0000 Subject: add eq constraints on associated constants --- compiler/rustc_interface/src/util.rs | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'compiler/rustc_interface/src') diff --git a/compiler/rustc_interface/src/util.rs b/compiler/rustc_interface/src/util.rs index cb51555f5ca..abecc8d1a8b 100644 --- a/compiler/rustc_interface/src/util.rs +++ b/compiler/rustc_interface/src/util.rs @@ -738,8 +738,9 @@ impl<'a, 'b> ReplaceBodyWithLoop<'a, 'b> { | ast::GenericArg::Const(_) => false, }, ast::AngleBracketedArg::Constraint(c) => match c.kind { - ast::AssocTyConstraintKind::Bound { .. } => true, - ast::AssocTyConstraintKind::Equality { ref ty } => { + ast::AssocConstraintKind::Bound { .. } => true, + ast::AssocConstraintKind::ConstEquality { .. } => false, + ast::AssocConstraintKind::Equality { ref ty } => { involves_impl_trait(ty) } }, -- cgit 1.4.1-3-g733a5