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

GH-41199: [C#] Fix accessing values of a sliced decimal array #41200

Merged
merged 1 commit into from
Apr 15, 2024

Conversation

adamreeve
Copy link
Contributor

@adamreeve adamreeve commented Apr 15, 2024

Rationale for this change

Fixes a bug where getting values from a sliced Decimal128Array or Decimal256Array would return the wrong values.

What changes are included in this PR?

Updates the various Get* methods in Decimal128Array and Decimal256Array to account for the array offset.

Are these changes tested?

Yes, I've added new unit tests.

Are there any user-facing changes?

Yes, this is a user-facing bug fix.

Copy link

⚠️ GitHub issue #41199 has been automatically assigned in GitHub to PR creator.

Copy link
Contributor

@CurtHagenlocher CurtHagenlocher left a comment

Choose a reason for hiding this comment

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

Thanks! Apparently I botched slicing on nearly all the changes I made :/.

@CurtHagenlocher CurtHagenlocher merged commit fec096a into apache:main Apr 15, 2024
9 checks passed
@CurtHagenlocher CurtHagenlocher removed the awaiting review Awaiting review label Apr 15, 2024
@github-actions github-actions bot added the awaiting committer review Awaiting committer review label Apr 15, 2024
@adamreeve adamreeve deleted the decimal_slices branch April 15, 2024 20:16
@adamreeve
Copy link
Contributor Author

Thanks! Apparently I botched slicing on nearly all the changes I made :/.

To be fair it looks like slicing wasn't considered in a lot of the existing code either so that's understandable

Copy link

After merging your PR, Conbench analyzed the 5 benchmarking runs that have been run so far on merge-commit fec096a.

There were no benchmark performance regressions. 🎉

The full Conbench report has more details. It also includes information about 12 possible false positives for unstable benchmarks that are known to sometimes produce them.

tolleybot pushed a commit to tmct/arrow that referenced this pull request May 2, 2024
…pache#41200)

### Rationale for this change

Fixes a bug where getting values from a sliced `Decimal128Array` or `Decimal256Array` would return the wrong values.

### What changes are included in this PR?

Updates the various `Get*` methods in `Decimal128Array` and `Decimal256Array` to account for the array offset.

### Are these changes tested?

Yes, I've added new unit tests.

### Are there any user-facing changes?

Yes, this is a user-facing bug fix.
* GitHub Issue: apache#41199

Authored-by: Adam Reeve <adreeve@gmail.com>
Signed-off-by: Curt Hagenlocher <curt@hagenlocher.org>
vibhatha pushed a commit to vibhatha/arrow that referenced this pull request May 25, 2024
…pache#41200)

### Rationale for this change

Fixes a bug where getting values from a sliced `Decimal128Array` or `Decimal256Array` would return the wrong values.

### What changes are included in this PR?

Updates the various `Get*` methods in `Decimal128Array` and `Decimal256Array` to account for the array offset.

### Are these changes tested?

Yes, I've added new unit tests.

### Are there any user-facing changes?

Yes, this is a user-facing bug fix.
* GitHub Issue: apache#41199

Authored-by: Adam Reeve <adreeve@gmail.com>
Signed-off-by: Curt Hagenlocher <curt@hagenlocher.org>
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