Auto merge of #51475 - GuillaumeGomez:fix-error-codes, r=Manishearth

Fix error codes
This commit is contained in:
bors 2018-06-10 22:30:14 +00:00
commit b202bebdee
11 changed files with 23 additions and 24 deletions

View file

@ -24,7 +24,7 @@ trait Trait<'a> { }
impl Trait<'b> for Cell<&'a u32> { }
fn foo(x: Cell<&'x u32>) -> impl Trait<'y>
//~^ ERROR hidden type for `impl Trait` captures lifetime that does not appear in bounds [E0909]
//~^ ERROR hidden type for `impl Trait` captures lifetime that does not appear in bounds [E0700]
where 'x: 'y
{
x

View file

@ -1,4 +1,4 @@
error[E0909]: hidden type for `impl Trait` captures lifetime that does not appear in bounds
error[E0700]: hidden type for `impl Trait` captures lifetime that does not appear in bounds
--> $DIR/region-escape-via-bound.rs:26:29
|
LL | fn foo(x: Cell<&'x u32>) -> impl Trait<'y>
@ -8,7 +8,7 @@ note: hidden type `std::cell::Cell<&'x u32>` captures the lifetime 'x as defined
--> $DIR/region-escape-via-bound.rs:26:1
|
LL | / fn foo(x: Cell<&'x u32>) -> impl Trait<'y>
LL | | //~^ ERROR hidden type for `impl Trait` captures lifetime that does not appear in bounds [E0909]
LL | | //~^ ERROR hidden type for `impl Trait` captures lifetime that does not appear in bounds [E0700]
LL | | where 'x: 'y
LL | | {
LL | | x
@ -17,4 +17,4 @@ LL | | }
error: aborting due to previous error
For more information about this error, try `rustc --explain E0909`.
For more information about this error, try `rustc --explain E0700`.