Skip to content

Add Strongly Typed Array Slice (#3929)#3930

Merged
tustvold merged 3 commits intoapache:masterfrom
tustvold:add-primitive-array-slice
Mar 28, 2023
Merged

Add Strongly Typed Array Slice (#3929)#3930
tustvold merged 3 commits intoapache:masterfrom
tustvold:add-primitive-array-slice

Conversation

@tustvold
Copy link
Contributor

@tustvold tustvold commented Mar 24, 2023

Which issue does this PR close?

Part of #3880
Closes #3929

Rationale for this change

What changes are included in this PR?

Are there any user-facing changes?

This is a breaking change, as calling slice on a concrete array will now return the concrete array. This change could be made as a non-breaking change, but I want to flush out the redundant downcasting.

@tustvold tustvold added the api-change Changes to the arrow API label Mar 24, 2023
@github-actions github-actions bot added the arrow Changes to the arrow crate label Mar 24, 2023
@tustvold tustvold marked this pull request as draft March 24, 2023 11:19
@tustvold tustvold changed the title Add PrimitiveArray slice (#3880) Add Strongly Typed Array Slice (#3929) Mar 24, 2023
@tustvold tustvold marked this pull request as ready for review March 24, 2023 12:42
@tustvold tustvold force-pushed the add-primitive-array-slice branch from e12f5b6 to b725a19 Compare March 24, 2023 12:42
@github-actions github-actions bot added the parquet Changes to the parquet crate label Mar 24, 2023
@tustvold tustvold force-pushed the add-primitive-array-slice branch from b725a19 to 18d14f8 Compare March 24, 2023 12:43
@tustvold tustvold requested a review from alamb March 25, 2023 13:57
Copy link
Contributor

@alamb alamb left a comment

Choose a reason for hiding this comment

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

I think changing it so slice() if you have a concrete Array gives the concrete type.

I double checked and Array::slice() still appears to return an ArrayRef which I think makes sense.

@tustvold tustvold merged commit a667af8 into apache:master Mar 28, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api-change Changes to the arrow API arrow Changes to the arrow crate parquet Changes to the parquet crate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Strongly Typed Array Slicing

2 participants