Move span in error (fixup #22764)

This commit is contained in:
Manish Goregaokar 2015-03-05 01:32:48 +05:30
parent 3d3ccfff9e
commit 931c55ab00

View file

@ -18,11 +18,10 @@ trait Collection { fn len(&self) -> usize; }
struct List<'a, T: ListItem<'a>> {
//~^ ERROR the parameter type `T` may not live long enough
//~^^ HELP consider adding an explicit lifetime bound
//~^^^ NOTE ...so that the reference type `&'a [T]` does not outlive the data it points at
//~^^ NOTE ...so that the reference type `&'a [T]` does not outlive the data it points at
slice: &'a [T]
}
//~^ HELP consider adding an explicit lifetime bound
impl<'a, T: ListItem<'a>> Collection for List<'a, T> {
fn len(&self) -> usize {
0