Skip to content

Conversation

@rluvaton
Copy link
Member

@rluvaton rluvaton commented Feb 8, 2026

Which issue does this PR close?

N/A

Rationale for this change

Allow to make easy changes without validation (for example replace the values)

What changes are included in this PR?

added 2 functions

Are these changes tested?

yes

Are there any user-facing changes?

yes new functions

@github-actions github-actions bot added the arrow Changes to the arrow crate label Feb 8, 2026
data_type: DataType,
run_ends: RunEndBuffer<R::Native>,
values: ArrayRef,
) -> Self {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need to add force validate here like for other arrays

pub unsafe fn new_unchecked(keys: PrimitiveArray<K>, values: ArrayRef) -> Self {
if cfg!(feature = "force_validate") {
return Self::new(keys, values);
}

pub unsafe fn new_unchecked(
offsets: OffsetBuffer<T::Offset>,
values: Buffer,
nulls: Option<NullBuffer>,
) -> Self {
if cfg!(feature = "force_validate") {
return Self::new(offsets, values, nulls);
}
Self {
data_type: T::DATA_TYPE,

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree -- we should make REE consistent with other arrays

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

arrow Changes to the arrow crate

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants