outlive `'anon` in `no_restriction()`.
If `no_restriction()` were to use `&T` instead of `&()` as an argument, the
-compiler would have added an implied bound [implied
-bound](https://rust-lang.github.io/rfcs/2089-implied-bounds.html), causing this
-to compile.
+compiler would have added an implied bound, causing this to compile.
This error can be resolved by explicitly naming the elided lifetime for `x` and
then explicily requiring that the generic parameter `T` outlives that lifetime:
| ^^^^^^^^^^^^^^^^^^^^^
help: consider adding an explicit lifetime bound...
|
-LL | fn no_restriction<T: 'a>(x: &()) -> &() {
- | ++++
+LL | fn no_restriction<'a, T: 'a>(x: &()) -> &() {
+ | +++ ++++
error: aborting due to previous error