From f8fab65861a1f62f2c806beb957967ffa1b4e5f9 Mon Sep 17 00:00:00 2001 From: topecongiro Date: Thu, 20 Dec 2018 00:52:55 +0900 Subject: [PATCH] Fix build in nightly cc https://github.com/rust-lang/rust/pull/56481. --- src/semcheck/mismatch.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/semcheck/mismatch.rs b/src/semcheck/mismatch.rs index d3f0481fe081e..335d2f19827f1 100644 --- a/src/semcheck/mismatch.rs +++ b/src/semcheck/mismatch.rs @@ -8,7 +8,7 @@ use rustc::{ hir::def_id::DefId, ty::{ self, - relate::{Relate, RelateResult, TypeRelation}, + relate::{Relate, RelateResult, TraitObjectMode, TypeRelation}, subst::Substs, Ty, TyCtxt, Visibility::Public, @@ -94,6 +94,10 @@ impl<'a, 'gcx, 'tcx> TypeRelation<'a, 'gcx, 'tcx> for MismatchRelation<'a, 'gcx, "Mismatch" } + fn trait_object_mode(&self) -> TraitObjectMode { + TraitObjectMode::NoSquash + } + fn a_is_expected(&self) -> bool { true }