change ConstEvaluatable to use ty::Const
This commit is contained in:
@@ -318,10 +318,10 @@ fn const_evaluatable_predicates_of<'tcx>(
|
||||
fn visit_anon_const(&mut self, c: &'tcx hir::AnonConst) {
|
||||
let def_id = self.tcx.hir().local_def_id(c.hir_id);
|
||||
let ct = ty::Const::from_anon_const(self.tcx, def_id);
|
||||
if let ty::ConstKind::Unevaluated(uv) = ct.kind() {
|
||||
if let ty::ConstKind::Unevaluated(_) = ct.kind() {
|
||||
let span = self.tcx.hir().span(c.hir_id);
|
||||
self.preds.insert((
|
||||
ty::Binder::dummy(ty::PredicateKind::ConstEvaluatable(uv))
|
||||
ty::Binder::dummy(ty::PredicateKind::ConstEvaluatable(ct))
|
||||
.to_predicate(self.tcx),
|
||||
span,
|
||||
));
|
||||
|
||||
Reference in New Issue
Block a user