Skip to content

Commit f55a4c3

Browse files
committed
not
Signed-off-by: Joe Isaacs <[email protected]>
1 parent 7c123f7 commit f55a4c3

File tree

3 files changed

+7
-5
lines changed

3 files changed

+7
-5
lines changed

vortex-array/src/expr/exprs/is_null.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
use std::fmt::Formatter;
55
use std::ops::Not;
6-
6+
use is_null::IsNullFn;
77
use vortex_dtype::DType;
88
use vortex_dtype::Nullability;
99
use vortex_error::VortexExpect;
@@ -115,7 +115,7 @@ impl VTable for IsNull {
115115
}
116116

117117
fn expr_v2(&self, view: &ExpressionView<Self>) -> VortexResult<Expression> {
118-
ScalarFnExprExt::try_new_expr(&is_null::IsNull, EmptyOptions, view.children().clone())
118+
ScalarFnExprExt::try_new_expr(&IsNullFn, EmptyOptions, view.children().clone())
119119
}
120120
}
121121

vortex-array/src/expr/vtable.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,7 @@ pub trait VTable: 'static + Sized + Send + Sync {
156156

157157
/// **For internal usage**. This will return an Expression that is part of the
158158
/// expression -> new_expression migration.
159+
#[doc(hidden)]
159160
fn expr_v2(&self, expr: &ExpressionView<Self>) -> VortexResult<Expression> {
160161
Ok(expr.deref().clone())
161162
}

vortex-array/src/scalar_fns/is_null/mod.rs

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
// SPDX-License-Identifier: Apache-2.0
22
// SPDX-FileCopyrightText: Copyright the Vortex contributors
33

4+
use std::ops::Not;
45
use vortex_dtype::DType;
56
use vortex_dtype::Nullability::NonNullable;
67
use vortex_error::VortexResult;
@@ -19,8 +20,8 @@ use crate::expr::functions::EmptyOptions;
1920
use crate::expr::functions::ExecutionArgs;
2021
use crate::expr::functions::VTable;
2122

22-
pub struct IsNull;
23-
impl VTable for IsNull {
23+
pub struct IsNullFn;
24+
impl VTable for IsNullFn {
2425
type Options = EmptyOptions;
2526

2627
fn id(&self) -> ExprId {
@@ -46,7 +47,7 @@ impl VTable for IsNull {
4647
Ok(match args.input_datums(0) {
4748
Datum::Scalar(sc) => Datum::Scalar(sc.is_invalid().into()),
4849
Datum::Vector(vec) => Vector::Bool(BoolVector::new(
49-
vec.validity().to_bit_buffer(),
50+
vec.validity().to_bit_buffer().not(),
5051
Mask::AllTrue(vec.len()),
5152
))
5253
.into(),

0 commit comments

Comments
 (0)