Skip to content

Commit

Permalink
Autoderef in librustc_mir
Browse files Browse the repository at this point in the history
  • Loading branch information
jonas-schievink committed Feb 12, 2016
1 parent 003879c commit 53b7464
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion src/librustc_mir/build/scope.rs
Expand Up @@ -488,7 +488,7 @@ impl<'a,'tcx> Builder<'a,'tcx> {
let funcdid = match self.hir.tcx().lang_items.require(lang_item) {
Ok(d) => d,
Err(m) => {
self.hir.tcx().sess.fatal(&*m)
self.hir.tcx().sess.fatal(&m)
}
};
Constant {
Expand Down
4 changes: 2 additions & 2 deletions src/librustc_mir/hair/cx/expr.rs
Expand Up @@ -114,7 +114,7 @@ impl<'tcx> Mirror<'tcx> for &'tcx hir::Expr {
}

hir::ExprBlock(ref blk) => {
ExprKind::Block { body: &**blk }
ExprKind::Block { body: &blk }
}

hir::ExprAssign(ref lhs, ref rhs) => {
Expand Down Expand Up @@ -277,7 +277,7 @@ impl<'tcx> Mirror<'tcx> for &'tcx hir::Expr {
});
ExprKind::Closure {
closure_id: def_id,
substs: &**substs,
substs: &substs,
upvars: upvars,
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/librustc_mir/hair/cx/pattern.rs
Expand Up @@ -90,7 +90,7 @@ impl<'patcx, 'cx, 'tcx> PatCx<'patcx, 'cx, 'tcx> {
Some(const_expr) => {
let pat = const_eval::const_expr_to_pat(self.cx.tcx, const_expr,
pat.span);
return self.to_pattern(&*pat);
return self.to_pattern(&pat);
}
None => {
self.cx.tcx.sess.span_bug(
Expand Down

0 comments on commit 53b7464

Please sign in to comment.