Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion arrow-array/src/scalar.rs
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ use crate::Array;
/// let r = eq(&a, &b).unwrap();
/// let values: Vec<_> = r.values().iter().collect();
/// assert_eq!(values, &[true, false, false, false, false]);
pub trait Datum {
pub trait Datum: Send + Sync {
/// Returns the value for this [`Datum`] and a boolean indicating if the value is scalar
fn get(&self) -> (&dyn Array, bool);
}
Expand Down Expand Up @@ -144,3 +144,6 @@ impl<T: Array> Datum for Scalar<T> {
(&self.0, true)
}
}

unsafe impl<T: Array> Send for Scalar<T> {}
unsafe impl<T: Array> Sync for Scalar<T> {}