You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
According to CRuby manual, Fixnum#bit_length returns "the bit position of the highest bit which is different to the sign bit". In other words, check 0 bit position for negative numbers.
According to CRuby manual,
Fixnum#bit_length
returns "the bit position of the highest bit which is different to the sign bit". In other words, check 0 bit position for negative numbers.In JRuby implementation it returns
64 - Long.numberOfLeadingZeros(value)
.Long.numberOfLeadingZeros(value)
returns 0 ifvalue
is negative, so the value is fixed to 64 in the cases.Environment
Expected Behavior
Actual Behavior
The text was updated successfully, but these errors were encountered: