alamb opened a new pull request #885:
URL: https://github.com/apache/arrow-rs/pull/885


   (Built on https://github.com/apache/arrow-rs/pull/810, so to see the changes 
proposed in this PR just look at the last commit)
   
   # Which issue does this PR close?
   
   Closes https://github.com/apache/arrow-rs/issues/814
   Closes https://github.com/apache/arrow-rs/issues/85
   Related to https://github.com/apache/arrow-rs/issues/817
   
   # Rationale for this change
   Follow Arrow spec for `UnionArray`, make it possible to validate with 
generic code added in https://github.com/apache/arrow-rs/pull/810, and conform 
to Rust safety conventions. 
   
   See https://arrow.apache.org/docs/format/Columnar.html#union-layout for a 
description of the Union layout
   
   # What changes are included in this PR?
   
   1. Rename `UnionArray::new` to `unsafe UnionArray::new_unchecked()` to 
follow standard Rust safety conventions
   2. Add `UnionMode` to `DataType::Union` so the type carries information on 
expected format
   3. Update null values offset handling to match 
https://arrow.apache.org/docs/format/Columnar.html#union-layout 
   4. Add validation in ArrayData::validate 
   
   # Are there any user-facing changes?
   1. `UnionArray::new` has been renamed to `unsafe 
UnionArray::new_unchecked()` 
   2. Accepted `UnionArray` format is different
   


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