Skip to content

Commit

Permalink
change code position
Browse files Browse the repository at this point in the history
  • Loading branch information
doki23 committed Dec 13, 2024
1 parent ae846ca commit db61dde
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions encodings/zigzag/src/compute.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,13 @@ impl ComputeVTable for ZigZagEncoding {
}
}

impl FilterFn<ZigZagArray> for ZigZagEncoding {
fn filter(&self, array: &ZigZagArray, mask: FilterMask) -> VortexResult<ArrayData> {
let encoded = filter(&array.encoded(), mask)?;
Ok(ZigZagArray::try_new(encoded)?.into_array())
}
}

impl ScalarAtFn<ZigZagArray> for ZigZagEncoding {
fn scalar_at(&self, array: &ZigZagArray, index: usize) -> VortexResult<Scalar> {
let scalar = scalar_at(array.encoded(), index)?;
Expand Down Expand Up @@ -65,13 +72,6 @@ impl TakeFn<ZigZagArray> for ZigZagEncoding {
}
}

impl FilterFn<ZigZagArray> for ZigZagEncoding {
fn filter(&self, array: &ZigZagArray, mask: FilterMask) -> VortexResult<ArrayData> {
let encoded = filter(&array.encoded(), mask)?;
Ok(ZigZagArray::try_new(encoded)?.into_array())
}
}

trait ZigZagEncoded {
type Int: ZigZag;
}
Expand Down

0 comments on commit db61dde

Please sign in to comment.