PrimitiveArray::from_iter
should omit validity buffer if all values are valid
#1856
Labels
PrimitiveArray::from_iter
should omit validity buffer if all values are valid
#1856
Is your feature request related to a problem or challenge? Please describe what you are trying to do.
PrimitiveArray::from_iter
currently always initializes and returns a null_buffer, even when all values are valid.Describe the solution you'd like
Before constructing the
ArrayData
we could check the count of ones in the validity buffer and mapping it to None if all values are valid. This should not add any overhead as the number of nulls is counted anyway by theArrayData
constructor.The text was updated successfully, but these errors were encountered: