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

BUG: segfault inplace object reduceat, fixes #7465 #7466

Merged
merged 1 commit into from
Mar 27, 2016

Conversation

jaimefrio
Copy link
Member

No description provided.

np.add.reduceat(arr, np.arange(4), out=arr, axis=-1)
assert_array_equal(arr, out)
arr = np.ones((2, 4), dtype=object)
arr[0, :] = [[2] for i in range(4)]
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

heh, should have realized it was tge same here. why the last two lines here? copy paste error?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oops, should be gone now.

@seberg
Copy link
Member

seberg commented Mar 27, 2016

Thanks Jaime. I think my first mobile phone merge ;).

@seberg seberg merged commit 63f3f24 into numpy:master Mar 27, 2016
@jaimefrio jaimefrio deleted the inplace_reduceat_segfault branch March 27, 2016 08:38
jaimefrio added a commit to jaimefrio/numpy that referenced this pull request Mar 27, 2016
This is a follow up to numpy#7407 and numpy#7466. It fixes an error in the
comments (0 is the output and 1 is the input), moves them around so
they apply to both branches of the if/else, and changes memcpy to
memmove, since the memory segments can be overlapping, as pointed
out by Valgrind in a really old issue.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants