gccrs: Handle `async` functions in traits
[official-gcc.git] / gcc / testsuite / rust / compile / const9.rs
blobe71a62a33b1e1572fd5d2e8e411a76285cddfbe5
1 // { dg-options "-w -O0 -fdump-tree-gimple" }
2 const fn test(mut x: i32) -> i32 {
3     loop {
4         if x == 10 {
5             break;
6         }
8         x = x + 1;
9     }
10     return x;
13 const X: i32 = test(0);
15 fn main() {
16     // { dg-final { scan-tree-dump-times {x = 10} 1 gimple } }
17     let x = X;