about summary refs log tree commit diff
path: root/tests/mir-opt/lower_array_len.rs
diff options
context:
space:
mode:
Diffstat (limited to 'tests/mir-opt/lower_array_len.rs')
-rw-r--r--tests/mir-opt/lower_array_len.rs6
1 files changed, 1 insertions, 5 deletions
diff --git a/tests/mir-opt/lower_array_len.rs b/tests/mir-opt/lower_array_len.rs
index 1c30c4c89b9..62fc9ef67d6 100644
--- a/tests/mir-opt/lower_array_len.rs
+++ b/tests/mir-opt/lower_array_len.rs
@@ -7,11 +7,7 @@ pub fn array_bound<const N: usize>(index: usize, slice: &[u8; N]) -> u8 {
     // CHECK-LABEL: fn array_bound(
     // CHECK: [[len:_.*]] = const N;
     // CHECK: Lt(move {{_.*}}, move [[len]]);
-    if index < slice.len() {
-        slice[index]
-    } else {
-        42
-    }
+    if index < slice.len() { slice[index] } else { 42 }
 }
 
 // EMIT_MIR lower_array_len.array_bound_mut.NormalizeArrayLen.diff