Skip to content

Commit bc5dd2f

Browse files
committed
rustc: Suppress more derived errors
1 parent 0a8c039 commit bc5dd2f

File tree

1 file changed

+2
-0
lines changed
  • src/librustc/middle/typeck/check

1 file changed

+2
-0
lines changed

src/librustc/middle/typeck/check/mod.rs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1677,6 +1677,8 @@ fn check_expr_with_unifier(fcx: @fn_ctxt,
16771677
expr.span,
16781678
~"attempted to take value of method \
16791679
(try writing an anonymous function)");
1680+
// Add error type for the result
1681+
fcx.write_ty(expr.id, ty::mk_err(tcx));
16801682
}
16811683
}
16821684
None => {

0 commit comments

Comments
 (0)