Skip to content

Conversation

jturner314
Copy link
Member

See SparrowLii's comment regarding the bug fix. Renaming the function, inverting the sign of the return value, and changing the return type to usize make the function easier to understand and use, IMO.

@jturner314 jturner314 added the bug label May 13, 2021
@jturner314 jturner314 added this to the 0.15.2 milestone May 13, 2021
@jturner314 jturner314 force-pushed the fix-offset_from_ptr_to_memory branch from 65685ad to dd52e27 Compare May 13, 2021 00:19
bluss added a commit to jturner314/ndarray that referenced this pull request May 13, 2021
The first of the added tests failed because of bug rust-ndarray#998, and the fix is
verified by the test. The second and third testcases did not have an
error, but were added for completeness.
@bluss bluss force-pushed the fix-offset_from_ptr_to_memory branch from dd52e27 to a72c82f Compare May 13, 2021 07:14
bluss and others added 3 commits May 13, 2021 09:16
The first of the added tests failed because of bug rust-ndarray#998, and the fix is
verified by the test. The second and third testcases did not have an
error, but were added for completeness.

The first testcase is by SparrowLii, from the initial mention of the
bug.
@bluss bluss force-pushed the fix-offset_from_ptr_to_memory branch from a72c82f to 4ca0f49 Compare May 13, 2021 07:17
@bluss
Copy link
Member

bluss commented May 13, 2021

Thanks. I pushed in @SparrowLii's testcase + some more. Inserted as the first commit so that I can check it out and verify the failure and then later the fix.

@bluss bluss merged commit 28e4d4c into rust-ndarray:master May 13, 2021
@jturner314 jturner314 deleted the fix-offset_from_ptr_to_memory branch May 13, 2021 08:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants