Add lint for unused lifetimes

A step towards  #12805.

 This could be extended to warn for things like this as well (either in this or in another PR):
```
struct Foo<'a> {
    a: int
}
```
`LifetimeCollector` seems like a better name for what it actually does (and it could be then used in more cases).