Skip to content

ARROW-11952: [Rust] Make ArrayData --> GenericListArray fallable instead of panic!#9691

Closed
alamb wants to merge 1 commit into
apache:masterfrom
alamb:alamb/fallable_list_conversion
Closed

ARROW-11952: [Rust] Make ArrayData --> GenericListArray fallable instead of panic!#9691
alamb wants to merge 1 commit into
apache:masterfrom
alamb:alamb/fallable_list_conversion

Conversation

@alamb

@alamb alamb commented Mar 13, 2021

Copy link
Copy Markdown
Contributor

Background:

Left over cleanups suggested by from @sunchao on #9425

Broken out from #9508

Rationale:

Don't use panic! directly. However, since the caller of this function still calls unwrap(), I am not sure how much of an improvement this change really is. However it may set us up for a more safe future eventually

@github-actions

Copy link
Copy Markdown

@alamb

alamb commented Mar 14, 2021

Copy link
Copy Markdown
Contributor Author

I am not sure how much of an improvement this is and I would be happy to simply close the PR, but I didn't want to leave it unresolved outstanding

@sunchao sunchao left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Thanks for making the change @alamb . Given that the from method is user facing, I think it makes sense to make it recoverable (maybe we can implement TryFrom in future).

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.

2 participants