Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Always clear unused bits of BitArrays #10008

Merged
merged 2 commits into from
Dec 8, 2020

Conversation

HertzDevil
Copy link
Contributor

Fixes #8543. Does not affect #8494.

.new and #invert could also set unused bits in a BitArray, besides #[] according to #8494 (comment). These cases are also checked.

@straight-shoota straight-shoota added kind:bug A bug in the code. Does not apply to documentation, specs, etc. topic:stdlib:collection labels Dec 1, 2020
src/bit_array.cr Outdated Show resolved Hide resolved
Co-authored-by: Sijawusz Pur Rahnama <[email protected]>
@asterite asterite added this to the 1.0.0 milestone Dec 8, 2020
@asterite asterite merged commit d4a5b30 into crystal-lang:master Dec 8, 2020
@HertzDevil HertzDevil deleted the bug/bitarray-unused-bits branch December 9, 2020 14:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind:bug A bug in the code. Does not apply to documentation, specs, etc. topic:stdlib:collection
Projects
None yet
Development

Successfully merging this pull request may close these issues.

BitArray#==(BitArray) is broken
4 participants