From 22b308c0ca1664aa3d992cf7db4304ae1844c57c Mon Sep 17 00:00:00 2001 From: Nicholas Gates Date: Sat, 6 Apr 2024 21:58:25 +0100 Subject: [PATCH] Validity --- vortex-array2/src/array/bool/mod.rs | 1 + vortex-array2/src/array/primitive/mod.rs | 1 + 2 files changed, 2 insertions(+) diff --git a/vortex-array2/src/array/bool/mod.rs b/vortex-array2/src/array/bool/mod.rs index fc928d3f83..d171ffbb5f 100644 --- a/vortex-array2/src/array/bool/mod.rs +++ b/vortex-array2/src/array/bool/mod.rs @@ -33,6 +33,7 @@ impl BoolMetadata { // TODO(ngates): I think this could be a struct? pub trait BoolArray { fn buffer(&self) -> &Buffer; + #[allow(clippy::len_without_is_empty)] fn len(&self) -> usize; fn validity(&self) -> Option; } diff --git a/vortex-array2/src/array/primitive/mod.rs b/vortex-array2/src/array/primitive/mod.rs index 0e4a9cde42..d0ab1fe698 100644 --- a/vortex-array2/src/array/primitive/mod.rs +++ b/vortex-array2/src/array/primitive/mod.rs @@ -33,6 +33,7 @@ pub trait PrimitiveArray { fn dtype(&self) -> &DType; fn ptype(&self) -> PType; fn buffer(&self) -> &Buffer; + #[allow(clippy::len_without_is_empty)] fn len(&self) -> usize { self.buffer().len() / self.ptype().byte_width() }