1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

Simplify BLSR code

And suppress unary minus operator to unsigned type warnings by VC.
This commit is contained in:
Nobuyoshi Nakada 2022-07-08 15:59:25 +09:00
parent 9958ed61bc
commit 7bab788309
No known key found for this signature in database
GPG key ID: 7CD2805BFA3770C6
Notes: git 2022-07-08 17:27:44 +09:00

2
iseq.c
View file

@ -257,7 +257,7 @@ iseq_scan_bits(unsigned int page, iseq_bits_t bits, VALUE *code, iseq_value_itr_
original_iseq[page_offset + offset] = newop;
}
}
bits ^= bits & -bits; // Reset Lowest Set Bit (BLSR)
bits &= bits - 1; // Reset Lowest Set Bit (BLSR)
}
}