diff options
| author | Matthew Maurer <mmaurer@google.com> | 2024-04-29 23:54:27 +0000 |
|---|---|---|
| committer | Matthew Maurer <mmaurer@google.com> | 2024-04-30 00:02:49 +0000 |
| commit | 8101884b37473a4aee62dc7553c8f6373d31c5f7 (patch) | |
| tree | d0cb83c08b9a95b308af44ad05d14a265a6387d3 /tests/codegen/enum/enum-match.rs | |
| parent | a8a1d3a771850e1e364eb9010e98789ce758a817 (diff) | |
| download | rust-8101884b37473a4aee62dc7553c8f6373d31c5f7.tar.gz rust-8101884b37473a4aee62dc7553c8f6373d31c5f7.zip | |
codegen tests: Tolerate `range()` qualifications in enum tests
Current LLVM can infer range bounds on the i8s involved with these tests, and annotates it. Accept these bounds if present.
Diffstat (limited to 'tests/codegen/enum/enum-match.rs')
| -rw-r--r-- | tests/codegen/enum/enum-match.rs | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/codegen/enum/enum-match.rs b/tests/codegen/enum/enum-match.rs index f1c40f6695b..ced26c0a434 100644 --- a/tests/codegen/enum/enum-match.rs +++ b/tests/codegen/enum/enum-match.rs @@ -11,7 +11,7 @@ pub enum Enum0 { B, } -// CHECK: define noundef i8 @match0{{.*}} +// CHECK: define noundef{{( range\(i8 [0-9]+, [0-9]+\))?}} i8 @match0{{.*}} // CHECK-NEXT: start: // CHECK-NEXT: %1 = icmp eq i8 %0, 2 // CHECK-NEXT: %2 = and i8 %0, 1 @@ -32,7 +32,7 @@ pub enum Enum1 { C, } -// CHECK: define noundef i8 @match1{{.*}} +// CHECK: define noundef{{( range\(i8 [0-9]+, [0-9]+\))?}} i8 @match1{{.*}} // CHECK-NEXT: start: // CHECK-NEXT: %1 = add i8 %0, -2 // CHECK-NEXT: %2 = zext i8 %1 to i64 @@ -91,7 +91,7 @@ pub enum Enum2 { E, } -// CHECK: define noundef i8 @match2{{.*}} +// CHECK: define noundef{{( range\(i8 [0-9]+, [0-9]+\))?}} i8 @match2{{.*}} // CHECK-NEXT: start: // CHECK-NEXT: %1 = add i8 %0, 2 // CHECK-NEXT: %2 = zext i8 %1 to i64 |
