alamb opened a new issue, #14610: URL: https://github.com/apache/datafusion/issues/14610
### Is your feature request related to a problem or challenge? While reviewing https://github.com/apache/datafusion/pull/14575 from @wForget I noticed that the implementation of `repeat` could be better Specifically, it calls [String::repeat](https://doc.rust-lang.org/std/string/struct.String.html#method.repeat) which allocates and copies the string (before [append_value](https://docs.rs/arrow/latest/arrow/array/struct.GenericByteBuilder.html#tymethod.append_value) copies it again) ### Describe the solution you'd like I think we could avoid the allocation (aka the call to `String::repeat`) ### Describe alternatives you've considered I think we could avoid the copy using the `Write` implementation as explained on https://docs.rs/arrow/latest/arrow/array/type.GenericStringBuilder.html#example-incrementally-writing-strings-with-stdfmtwrite ### Additional context _No response_ -- 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: github-unsubscr...@datafusion.apache.org.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: github-unsubscr...@datafusion.apache.org For additional commands, e-mail: github-h...@datafusion.apache.org