]> git.lizzy.rs Git - rust.git/blob - src/test/ui/issues/issue-26638.stderr
Auto merge of #54624 - arielb1:evaluate-outlives, r=nikomatsakis
[rust.git] / src / test / ui / issues / issue-26638.stderr
1 error[E0106]: missing lifetime specifier
2   --> $DIR/issue-26638.rs:11:58
3    |
4 LL | fn parse_type(iter: Box<Iterator<Item=&str>+'static>) -> &str { iter.next() }
5    |                                                          ^ expected lifetime parameter
6    |
7    = help: this function's return type contains a borrowed value, but the signature does not say which one of `iter`'s 2 lifetimes it is borrowed from
8
9 error[E0106]: missing lifetime specifier
10   --> $DIR/issue-26638.rs:14:40
11    |
12 LL | fn parse_type_2(iter: fn(&u8)->&u8) -> &str { iter() }
13    |                                        ^ expected lifetime parameter
14    |
15    = help: this function's return type contains a borrowed value with an elided lifetime, but the lifetime cannot be derived from the arguments
16    = help: consider giving it an explicit bounded or 'static lifetime
17
18 error[E0106]: missing lifetime specifier
19   --> $DIR/issue-26638.rs:17:22
20    |
21 LL | fn parse_type_3() -> &str { unimplemented!() }
22    |                      ^ expected lifetime parameter
23    |
24    = help: this function's return type contains a borrowed value, but there is no value for it to be borrowed from
25    = help: consider giving it a 'static lifetime
26
27 error: aborting due to 3 previous errors
28
29 For more information about this error, try `rustc --explain E0106`.