]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-13497-2.stderr
Auto merge of #57108 - Mark-Simulacrum:license-remove, r=pietroalbini
[rust.git] / src / test / ui / issues / issue-13497-2.stderr
1 error[E0597]: `rawLines` does not live long enough
2   --> $DIR/issue-13497-2.rs:3:5
3    |
4 LL |     rawLines //~ ERROR `rawLines` does not live long enough
5    |     ^^^^^^^^ borrowed value does not live long enough
6 LL |         .iter().map(|l| l.trim()).collect()
7 LL | }
8    | - borrowed value only lives until here
9    |
10 note: borrowed value must be valid for the lifetime 'a as defined on the function body at 1:24...
11   --> $DIR/issue-13497-2.rs:1:24
12    |
13 LL | fn read_lines_borrowed<'a>() -> Vec<&'a str> {
14    |                        ^^
15
16 error: aborting due to previous error
17
18 For more information about this error, try `rustc --explain E0597`.