friendlymatthew commented on PR #7778:
URL: https://github.com/apache/arrow-rs/pull/7778#issuecomment-3006554320

   > @friendlymatthew Why are objects and lists treated as "pending" and not 
eagerly added? I am adding a function to parse JSON into Variant, and because 
of this, I am seeing a behavioral difference between Spark's `parse_json` 
expression and the rust implementation
   
   Hi, by eagerly added do you mean to the parent builder? We can't add an 
object or list to the parent builder's buffer until the object/list itself has 
been fully created because each nested object/list has its own header and we 
can't know what the header will be.
   
   What sort of behavioral differences are you seeing? If you call `.finish()` 
before operating on the builder, the object should be exactly the same as if it 
were to be done eagerly.


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