]> git.lizzy.rs Git - rust.git/blob - src/test/codegen/merge-functions.rs
Rollup merge of #88313 - jyn514:pre-push, r=Mark-Simulacrum
[rust.git] / src / test / codegen / merge-functions.rs
1 // compile-flags: -O
2 #![crate_type = "lib"]
3
4 // CHECK: @func2 = {{.*}}alias{{.*}}@func1
5
6 #[no_mangle]
7 pub fn func1(c: char) -> bool {
8     c == 's' || c == 'm' || c == 'h' || c == 'd' || c == 'w'
9 }
10
11 #[no_mangle]
12 pub fn func2(c: char) -> bool {
13     matches!(c, 's' | 'm' | 'h' | 'd' | 'w')
14 }