Skip to content

Commit

Permalink
Update span_label call to new api
Browse files Browse the repository at this point in the history
  • Loading branch information
Jonathan Turner committed May 13, 2016
1 parent 1b6afd1 commit ecadd7e
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/librustc_typeck/lib.rs
Expand Up @@ -199,8 +199,8 @@ pub fn emit_type_err<'a, 'gcx, 'tcx>(tcx: TyCtxt<'a, 'gcx, 'tcx>,
terr: &ty::error::TypeError<'tcx>,
msg: &str) {
let mut err = struct_span_err!(tcx.sess, span, E0211, "{}", msg);
err = err.span_label(span, &terr);
err = err.note_expected_found(&"type", &expected_ty, &found_ty);
err.span_label(span, &terr);
err.note_expected_found(&"type", &expected_ty, &found_ty);
tcx.note_and_explain_type_err(&mut err, terr, span);
err.emit();
}
Expand Down

0 comments on commit ecadd7e

Please sign in to comment.