Skip to content

Commit

Permalink
revert fmt
Browse files Browse the repository at this point in the history
  • Loading branch information
duongcongtoai committed Mar 29, 2023
1 parent 2a76528 commit 37a8b07
Showing 1 changed file with 5 additions and 9 deletions.
14 changes: 5 additions & 9 deletions datafusion/optimizer/src/push_down_limit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,14 @@

//! Optimizer rule to push down LIMIT in the query plan
//! It will push down through projection, limits (taking the smaller limit)
use std::sync::Arc;

use crate::optimizer::ApplyOrder;
use crate::{OptimizerConfig, OptimizerRule};
use datafusion_common::Result;
use datafusion_expr::{
logical_plan::{Join, JoinType, Limit, LogicalPlan, Sort, TableScan, Union},
CrossJoin,
};

use crate::optimizer::ApplyOrder;
use crate::{OptimizerConfig, OptimizerRule};
use std::sync::Arc;

/// Optimization rule that tries to push down LIMIT.
#[derive(Default)]
Expand Down Expand Up @@ -277,16 +275,14 @@ fn push_down_join(join: &Join, limit: usize) -> Option<Join> {
mod test {
use std::vec;

use super::*;
use crate::test::*;
use datafusion_expr::{
col, exists,
logical_plan::{builder::LogicalPlanBuilder, JoinType, LogicalPlan},
max,
};

use crate::test::*;

use super::*;

fn assert_optimized_plan_equal(plan: &LogicalPlan, expected: &str) -> Result<()> {
assert_optimized_plan_eq(Arc::new(PushDownLimit::new()), plan, expected)
}
Expand Down

0 comments on commit 37a8b07

Please sign in to comment.