]> git.lizzy.rs Git - rust.git/blob - tests/ui/regions/regions-infer-call.rs
Rollup merge of #106644 - alexcrichton:update-wasi-toolchain, r=cuviper
[rust.git] / tests / ui / regions / regions-infer-call.rs
1 // run-pass
2
3 fn takes_two(x: &isize, y: &isize) -> isize { *x + *y }
4
5 fn has_two<'a,'b>(x: &'a isize, y: &'b isize) -> isize {
6     takes_two(x, y)
7 }
8
9 pub fn main() {
10     assert_eq!(has_two(&20, &2), 22);
11 }