]> git.lizzy.rs Git - rust.git/blob - src/test/codegen/merge-functions.rs
Merge commit '8d14c94b5c0a66241b4244f1c60ac5859cec1d97' into clippyup
[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 }