Skip to content

Commit

Permalink
Simplify pattern
Browse files Browse the repository at this point in the history
  • Loading branch information
spastorino authored and matthewjasper committed Nov 21, 2019
1 parent ae9677c commit 3600695
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/librustc_codegen_ssa/mir/constant.rs
Expand Up @@ -14,8 +14,8 @@ impl<'a, 'tcx, Bx: BuilderMethods<'a, 'tcx>> FunctionCx<'a, 'tcx, Bx> {
constant: &mir::Constant<'tcx>,
) -> Result<&'tcx ty::Const<'tcx>, ErrorHandled> {
match constant.literal.val {
ty::ConstKind::Unevaluated(def_id, ref substs) => {
let substs = self.monomorphize(substs);
ty::ConstKind::Unevaluated(def_id, substs) => {
let substs = self.monomorphize(&substs);
let instance = ty::Instance::resolve(
self.cx.tcx(), ty::ParamEnv::reveal_all(), def_id, substs,
).unwrap();
Expand Down

0 comments on commit 3600695

Please sign in to comment.