]> git.lizzy.rs Git - rust.git/blob - src/test/ui/nll/closure-requirements/region-lbr1-does-outlive-lbr2-because-implied-bound.rs
Auto merge of #66911 - eddyb:nicer-rustc_regions, r=matthewjasper
[rust.git] / src / test / ui / nll / closure-requirements / region-lbr1-does-outlive-lbr2-because-implied-bound.rs
1 // Basic test for free regions in the NLL code. This test does not
2 // report an error because of the (implied) bound that `'b: 'a`.
3
4 // check-pass
5 // compile-flags:-Zborrowck=mir -Zverbose
6
7 fn foo<'a, 'b>(x: &'a &'b u32) -> &'a u32 {
8     &**x
9 }
10
11 fn main() {}