Skip to content

Commit

Permalink
Update E0207 to use struct_span_err, add span_label
Browse files Browse the repository at this point in the history
  • Loading branch information
shantanuraj committed Aug 5, 2016
1 parent 41fe4b7 commit bc25879
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions src/librustc_typeck/collect.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2314,8 +2314,12 @@ fn report_unused_parameter(ccx: &CrateCtxt,
kind: &str,
name: &str)
{
span_err!(ccx.tcx.sess, span, E0207,
"the {} parameter `{}` is not constrained by the \
impl trait, self type, or predicates",
kind, name);
struct_span_err!(
ccx.tcx.sess, span, E0207,
"the {} parameter `{}` is not constrained by the \
impl trait, self type, or predicates",
kind, name)
.span_label(span, &format!("unconstrained lifetime parameter"))
.emit();

}

0 comments on commit bc25879

Please sign in to comment.