diff --git a/arrow-array/src/scalar.rs b/arrow-array/src/scalar.rs index f2a696a8f329..52f726993166 100644 --- a/arrow-array/src/scalar.rs +++ b/arrow-array/src/scalar.rs @@ -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); } @@ -144,3 +144,6 @@ impl Datum for Scalar { (&self.0, true) } } + +unsafe impl Send for Scalar {} +unsafe impl Sync for Scalar {}