HaoYang670 commented on code in PR #2686:
URL: https://github.com/apache/arrow-rs/pull/2686#discussion_r966589860
##########
arrow/src/array/array_string.rs:
##########
@@ -129,8 +129,6 @@ impl<OffsetSize: OffsetSizeTrait>
GenericStringArray<OffsetSize> {
}
/// Convert a list array to a string array.
- /// This method is unsound because it does
- /// not check the utf-8 validation for each element.
fn from_list(v: GenericListArray<OffsetSize>) -> Self {
Review Comment:
Validating utf-8 is always slow (it has linear time complexity, I guess).
If users can make sure their values are valid, they can go the unsafe path.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]