Skip to content

Commit b2b29bc

Browse files
committed
fix clippy
1 parent 9ae93c0 commit b2b29bc

File tree

1 file changed

+7
-8
lines changed

1 file changed

+7
-8
lines changed

src/query/service/src/sql/planner/semantic/type_check.rs

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -471,9 +471,9 @@ impl<'a> TypeChecker<'a> {
471471
substring_for,
472472
..
473473
} => {
474-
let mut arguments = vec![expr.as_ref(), from_expr.as_ref()];
475-
if let Some(for_expr) = for_expr {
476-
arguments.push(for_expr.as_ref());
474+
let mut arguments = vec![expr.as_ref(), substring_from.as_ref()];
475+
if let Some(substring_for) = substring_for {
476+
arguments.push(substring_for.as_ref());
477477
}
478478
self.resolve_function(span, "substring", &arguments, required_type)
479479
.await?
@@ -1452,7 +1452,7 @@ impl<'a> TypeChecker<'a> {
14521452
quote: None,
14531453
span: span[0].clone(),
14541454
},
1455-
args: vec![(*arg0).clone()],
1455+
args: vec![(*arg_x).clone()],
14561456
params: vec![],
14571457
}],
14581458
None,
@@ -1980,10 +1980,9 @@ impl<'a> TypeChecker<'a> {
19801980
expr: Box::new(
19811981
self.clone_expr_with_replacement(expr.as_ref(), replacement_fn)?,
19821982
),
1983-
substring_from: Box::new(self.clone_expr_with_replacement(
1984-
substring_from_expr.as_ref(),
1985-
replacement_fn,
1986-
)?),
1983+
substring_from: Box::new(
1984+
self.clone_expr_with_replacement(substring_from.as_ref(), replacement_fn)?,
1985+
),
19871986
substring_for: if let Some(substring_for_expr) = substring_for {
19881987
Some(Box::new(self.clone_expr_with_replacement(
19891988
substring_for_expr.as_ref(),

0 commit comments

Comments
 (0)