Skip to content

Commit

Permalink
remove unnecessary cast
Browse files Browse the repository at this point in the history
  • Loading branch information
huaxingao committed Aug 19, 2024
1 parent 1375633 commit 6d1276a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions native/core/src/execution/datafusion/planner.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1608,7 +1608,7 @@ impl PhysicalPlanner {
}
},
LowerFrameBoundStruct::Preceding(offset) => {
let offset_value = offset.offset.abs() as i64;
let offset_value = offset.offset.abs();
match units {
WindowFrameUnits::Rows => WindowFrameBound::Preceding(ScalarValue::UInt64(
Some(offset_value as u64),
Expand Down Expand Up @@ -1647,7 +1647,7 @@ impl PhysicalPlanner {
WindowFrameBound::Following(ScalarValue::UInt64(Some(offset.offset as u64)))
}
WindowFrameUnits::Range | WindowFrameUnits::Groups => {
WindowFrameBound::Following(ScalarValue::Int64(Some(offset.offset as i64)))
WindowFrameBound::Following(ScalarValue::Int64(Some(offset.offset)))
}
},
UpperFrameBoundStruct::CurrentRow(_) => WindowFrameBound::CurrentRow,
Expand Down

0 comments on commit 6d1276a

Please sign in to comment.