Skip to content

Conversation

@DRMacIver
Copy link
Contributor

Pythons list implementation has a special case to ensure that
x.extend(x) is the same as x.extend(list(x)). i.e. it doesn't notice
changes to the size of the list during the extend.

Previously this case would not have been handled correctly by
bitarray. This changes that by checking what the size of the other
array is before we make any changes. This ensures both that this works
correctly and also (importantly) that we don't try to write past the
end of the array.

Pythons list implementation has a special case to ensure that
x.extend(x) is the same as x.extend(list(x)). i.e. it doesn't notice
changes to the size of the list during the extend.

Previously this case would not have been handled correctly by
bitarray. This changes that by checking what the size of the other
array is before we make any changes. This ensures both that this works
correctly and also (importantly) that we don't try to write past the
end of the array.
@andre-merzky
Copy link

Hey @DRMacIver,

this repo has been silent for quite a while, and we thus created a fork at https://github.com/diamondman/bitarray/.

If you are interested, please feel free to transplant your pull request to the forked repo, we would be very happy to begin the code review and merge into bitarray before pushing out a new release. If you do not have the time to do so, we would kindly ask your permission to do the PR transfer our-self. If you could ping back in the next couple of days, one way or the other, that would be great.

Many thanks!

@ilanschnell
Copy link
Owner

Thanks for the PR! (And sorry for merging it almost 3 years later)

@ilanschnell ilanschnell merged commit 7d2b4c8 into ilanschnell:master May 29, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants