Skip to content

Commit

Permalink
working version
Browse files Browse the repository at this point in the history
  • Loading branch information
barak1412 committed Sep 27, 2024
1 parent 71a8b05 commit b6c3491
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions crates/polars-core/src/chunked_array/ops/zip.rs
Original file line number Diff line number Diff line change
Expand Up @@ -375,10 +375,10 @@ impl ChunkZip<StructType> for StructChunked {
.all(|(r, m)| r == m));

let combine = if l.null_count() == 0 {
|r: Option<&Bitmap>, m: &Bitmap| r.map(|r| arrow::bitmap::or_not(r, m))
|r: Option<&Bitmap>, m: &Bitmap| r.map(|r| arrow::bitmap::or(r, m))
} else {
|r: Option<&Bitmap>, m: &Bitmap| {
Some(r.map_or_else(|| m.clone(), |r| arrow::bitmap::and(r, m)))
Some(r.map_or_else(|| m.clone(), |r| arrow::bitmap::and_not(r, m)))
}
};

Expand Down Expand Up @@ -411,10 +411,10 @@ impl ChunkZip<StructType> for StructChunked {
.all(|(l, m)| l == m));

let combine = if r.null_count() == 0 {
|r: Option<&Bitmap>, m: &Bitmap| r.map(|r| arrow::bitmap::or(r, m))
|l: Option<&Bitmap>, m: &Bitmap| l.map(|l| arrow::bitmap::or_not(l, m))
} else {
|r: Option<&Bitmap>, m: &Bitmap| {
Some(r.map_or_else(|| m.clone(), |r| arrow::bitmap::and_not(r, m)))
|l: Option<&Bitmap>, m: &Bitmap| {
Some(l.map_or_else(|| m.clone(), |l| arrow::bitmap::and(l, m)))
}
};

Expand Down

0 comments on commit b6c3491

Please sign in to comment.