From 08c57a3573cb0faed8ca82282072c3fc7bb7f29b Mon Sep 17 00:00:00 2001 From: Jefffrey Date: Thu, 2 Jul 2026 09:24:09 +0900 Subject: [PATCH] Replace conversion of binary->string in arrow-row from arraydata to direct construction --- arrow-row/src/variable.rs | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/arrow-row/src/variable.rs b/arrow-row/src/variable.rs index aeb7f888b00e..b421b5e27ad1 100644 --- a/arrow-row/src/variable.rs +++ b/arrow-row/src/variable.rs @@ -401,14 +401,11 @@ pub unsafe fn decode_string( return GenericStringArray::from(decoded); } - let builder = decoded - .into_data() - .into_builder() - .data_type(GenericStringArray::::DATA_TYPE); + let (offsets, values, nulls) = decoded.into_parts(); // SAFETY: // Row data must have come from a valid UTF-8 array - GenericStringArray::from(unsafe { builder.build_unchecked() }) + unsafe { GenericStringArray::new_unchecked(offsets, values, nulls) } } /// Decodes a string view array from `rows` with the provided `options`