timmyb32r opened a new pull request, #11931:
URL: https://github.com/apache/arrow-rs/pull/11931

   ### Which issue does this PR close?
   
   None — standalone bug fix.
   
   ### Rationale for this change
   
   Formatting a `DataType` and parsing it back can change field names or fail 
when names contain quotes or backslashes. The parser preserves escape 
characters instead of decoding them, and list field names are formatted without 
escaping.
   
   For example, a struct field named `a"b` gains an extra backslash after a 
round trip.
   
   ### What changes are included in this PR?
   
   Decode escaped quotes, backslashes, control characters, and Unicode escapes 
in quoted strings. Reject malformed escape sequences.
   
   Escape custom field names consistently for List, LargeList, ListView, 
LargeListView, and FixedSizeList.
   
   ### Are these changes tested?
   
   Added regression tests covering:
   - Round trips for struct field names, list field names, and timestamp 
strings containing special characters.
   - The exact escaped representation of list field names.
   - Decoding supported escapes and rejecting malformed escapes and invalid 
Unicode scalar values.
   
   The round-trip regression test fails before the fix and passes afterward.
   
   ### Are there any significant user-facing changes?
   
   No breaking public API changes. Malformed escape sequences now return a 
parse error.
   
   ### AI assistance
   
   Codex identified the issue, generated the fix and regression tests, ran 
validation, and drafted this PR description.


-- 
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]

Reply via email to