Skip to content

Commit acc678c

Browse files
committed
simpler
Signed-off-by: Robert Kruszewski <github@robertk.io>
1 parent 968400d commit acc678c

2 files changed

Lines changed: 1 addition & 2 deletions

File tree

vortex-btrblocks/src/compressor/bool/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,7 @@ impl Scheme for ConstantScheme {
140140
}
141141

142142
// Only compress non-nullable or all-valid nullable arrays.
143-
if stats.src.dtype().is_nullable() && !stats.src.all_valid()? {
143+
if stats.src.dtype().is_nullable() && stats.null_count > 0 {
144144
return Ok(0.0);
145145
}
146146

vortex-btrblocks/src/compressor/bool/stats.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,6 @@ use crate::sample::sample;
1919
pub struct BoolStats {
2020
pub(crate) src: BoolArray,
2121
/// Number of null values.
22-
#[allow(dead_code)]
2322
pub(crate) null_count: u32,
2423
/// Number of non-null values.
2524
pub(crate) value_count: u32,

0 commit comments

Comments
 (0)