2017-11-16 22:59:45 -08:00
|
|
|
error[E0496]: lifetime name `'s` shadows a lifetime name that is already in scope
|
|
|
|
--> $DIR/shadow.rs:17:12
|
|
|
|
|
|
2018-02-23 03:42:32 +03:00
|
|
|
LL | impl Foo<&'s u8> {
|
2017-11-16 22:59:45 -08:00
|
|
|
| -- first declared here
|
2018-02-23 03:42:32 +03:00
|
|
|
LL | fn bar<'s>(&self, x: &'s u8) {} //~ ERROR shadows a lifetime name
|
2017-11-16 22:59:45 -08:00
|
|
|
| ^^ lifetime 's already in scope
|
|
|
|
|
|
|
|
error[E0496]: lifetime name `'s` shadows a lifetime name that is already in scope
|
|
|
|
--> $DIR/shadow.rs:18:19
|
|
|
|
|
|
2018-02-23 03:42:32 +03:00
|
|
|
LL | impl Foo<&'s u8> {
|
2017-11-16 22:59:45 -08:00
|
|
|
| -- first declared here
|
2018-02-25 02:01:39 +03:00
|
|
|
LL | fn bar<'s>(&self, x: &'s u8) {} //~ ERROR shadows a lifetime name
|
2018-02-23 03:42:32 +03:00
|
|
|
LL | fn baz(x: for<'s> fn(&'s u32)) {} //~ ERROR shadows a lifetime name
|
2017-11-16 22:59:45 -08:00
|
|
|
| ^^ lifetime 's already in scope
|
|
|
|
|
|
|
|
error: aborting due to 2 previous errors
|
|
|
|
|
2018-02-19 21:40:25 +01:00
|
|
|
If you want more information on this error, try using "rustc --explain E0496"
|