Skip to content

Commit d2cda90

Browse files
committed
fix(clippy): redundant variables in simd.rs
1 parent 091de55 commit d2cda90

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

src/intrinsic/simd.rs

+1-3
Original file line numberDiff line numberDiff line change
@@ -531,16 +531,14 @@ pub fn generic_simd_intrinsic<'a, 'gcc, 'tcx>(
531531
let sign_shift = bx.context.new_rvalue_from_int(elem_type, elem_size as i32 - 1);
532532
let one = bx.context.new_rvalue_one(elem_type);
533533

534-
let mut shift = 0;
535534
for i in 0..in_len {
536535
let elem =
537536
bx.extract_element(vector, bx.context.new_rvalue_from_int(bx.int_type, i as i32));
538537
let shifted = elem >> sign_shift;
539538
let masked = shifted & one;
540539
result = result
541540
| (bx.context.new_cast(None, masked, result_type)
542-
<< bx.context.new_rvalue_from_int(result_type, shift));
543-
shift += 1;
541+
<< bx.context.new_rvalue_from_int(result_type, i as i32));
544542
}
545543

546544
match *ret_ty.kind() {

0 commit comments

Comments
 (0)