]> git.lizzy.rs Git - rust.git/blob - src/test/ui/async-await/issues/issue-64964.rs
Add 'library/portable-simd/' from commit '1ce1c645cf27c4acdefe6ec8a11d1f0491954a99'
[rust.git] / src / test / ui / async-await / issues / issue-64964.rs
1 // check-pass
2 // incremental
3 // compile-flags: -Z query-dep-graph
4 // edition:2018
5
6 // Regression test for ICE related to `await`ing in a method + incr. comp. (#64964)
7
8 struct Body;
9 impl Body {
10     async fn next(&mut self) {
11         async {}.await
12     }
13 }
14
15 // Another reproduction: `await`ing with a variable from for-loop.
16
17 async fn bar() {
18     for x in 0..10 {
19         async { Some(x) }.await.unwrap();
20     }
21 }
22
23 fn main() {}