parent
2b7ea14cc4
commit
19a33371eb
2 changed files with 2 additions and 3 deletions
|
|
@ -2323,7 +2323,6 @@ fn report_unused_parameter(ccx: &CrateCtxt,
|
|||
"the {} parameter `{}` is not constrained by the \
|
||||
impl trait, self type, or predicates",
|
||||
kind, name)
|
||||
.span_label(span, &format!("unconstrained lifetime parameter"))
|
||||
.span_label(span, &format!("unconstrained {} parameter", kind))
|
||||
.emit();
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -11,7 +11,7 @@
|
|||
struct Foo;
|
||||
|
||||
impl<T: Default> Foo { //~ ERROR E0207
|
||||
//~| NOTE unconstrained lifetime parameter
|
||||
//~| NOTE unconstrained type parameter
|
||||
fn get(&self) -> T {
|
||||
<T as Default>::default()
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue