]> git.lizzy.rs Git - rust.git/blob - src/test/ui/lub-if.nll.stderr
Rollup merge of #53317 - estebank:abolish-ice, r=oli-obk
[rust.git] / src / test / ui / lub-if.nll.stderr
1 warning: not reporting region error due to nll
2   --> $DIR/lub-if.rs:38:9
3    |
4 LL |         s  //~ ERROR E0312
5    |         ^
6
7 warning: not reporting region error due to nll
8   --> $DIR/lub-if.rs:45:9
9    |
10 LL |         s  //~ ERROR E0312
11    |         ^
12
13 error: unsatisfied lifetime constraints
14   --> $DIR/lub-if.rs:34:8
15    |
16 LL | pub fn opt_str2<'a>(maybestr: &'a Option<String>) -> &'static str {
17    |                 -- lifetime `'a` defined here
18 LL |     if maybestr.is_none() {
19    |        ^^^^^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`
20
21 error: unsatisfied lifetime constraints
22   --> $DIR/lub-if.rs:43:8
23    |
24 LL | pub fn opt_str3<'a>(maybestr: &'a Option<String>) -> &'static str {
25    |                 -- lifetime `'a` defined here
26 LL |     if maybestr.is_some() {
27    |        ^^^^^^^^^^^^^^^^^^ requires that `'a` must outlive `'static`
28
29 error: aborting due to 2 previous errors
30