]> git.lizzy.rs Git - rust.git/commitdiff
bless output of ui test nll/outlives-suggestion-simple.rs
authorRemy Rakic <remy.rakic@gmail.com>
Sun, 29 Mar 2020 23:22:59 +0000 (01:22 +0200)
committerRemy Rakic <remy.rakic@gmail.com>
Sun, 29 Mar 2020 23:22:59 +0000 (01:22 +0200)
trivial diagnostics wording change

src/test/ui/nll/outlives-suggestion-simple.polonius.stderr

index 815744618f62c69e2b51b8157c0bc405b0f74621..dbbda62d2086c27f59d8c4fb355c686322521a1d 100644 (file)
@@ -72,6 +72,8 @@ LL |     (x, x)
    |
    = help: consider adding the following bound: `'a: 'c`
 
+help: add bound `'a: 'b + 'c`
+
 error: lifetime may not live long enough
   --> $DIR/outlives-suggestion-simple.rs:31:9
    |
@@ -106,16 +108,16 @@ LL |         self.x
    |
    = help: consider adding the following bound: `'b: 'a`
 
-error[E0521]: borrowed data escapes outside of function
+error[E0521]: borrowed data escapes outside of associated function
   --> $DIR/outlives-suggestion-simple.rs:73:9
    |
 LL |     fn get_bar(&self) -> Bar2 {
    |                -----
    |                |
-   |                `self` is declared here, outside of the function body
-   |                `self` is a reference that is only valid in the function body
+   |                `self` declared here, outside of the associated function body
+   |                `self` is a reference that is only valid in the associated function body
 LL |         Bar2::new(&self)
-   |         ^^^^^^^^^^^^^^^^ `self` escapes the function body here
+   |         ^^^^^^^^^^^^^^^^ `self` escapes the associated function body here
 
 error: aborting due to 10 previous errors