diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 0a3e578ec442a32e681e281f168fc8f807d760b0..e53593a0b1e5320e7dcc04acc658d08284292b25 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -10,7 +10,7 @@ cache: default: tags: - picodata - image: registry.gitlab.com/picodata/dockers/brod-builder:0.3 + image: registry.gitlab.com/picodata/dockers/brod-builder:0.7 build: stage: build diff --git a/src/ir/expression.rs b/src/ir/expression.rs index 0022e87f590d5a9380f95dc6f447aaf6eda3c14d..a72c8657518ddeb8d847f49af99089b09273dcca 100644 --- a/src/ir/expression.rs +++ b/src/ir/expression.rs @@ -366,7 +366,7 @@ impl Plan { vec![*target_idx] } else { // Reference in union tuple points to **both** left and right children. - targets.iter().copied().collect() + targets.to_vec() }; // Add new references and aliases to arena (if we need them). let r_id = self.nodes.add_ref(None, Some(new_targets), pos); @@ -404,7 +404,7 @@ impl Plan { let mut result: Vec<usize> = Vec::new(); let all_found = col_names.iter().all(|col| { map.get(*col).map_or(false, |pos| { - let new_targets: Vec<usize> = targets.iter().copied().collect(); + let new_targets: Vec<usize> = targets.to_vec(); // Add new references and aliases to arena (if we need them). let r_id = self.nodes.add_ref(None, Some(new_targets), *pos); if need_aliases { diff --git a/src/ir/operator.rs b/src/ir/operator.rs index 4ad8b7e84a19b9f7007873e62f64f833870a510f..a016a794fd8704b4156eee633253dda41ab522bc 100644 --- a/src/ir/operator.rs +++ b/src/ir/operator.rs @@ -273,7 +273,7 @@ impl Relational { match self { Relational::ScanRelation { alias, relation, .. - } => Ok(alias.as_deref().or_else(|| Some(relation.as_str()))), + } => Ok(alias.as_deref().or(Some(relation.as_str()))), Relational::ScanSubQuery { alias, .. } => Ok(alias.as_deref()), Relational::Projection { .. } | Relational::Selection { .. } diff --git a/src/ir/value.rs b/src/ir/value.rs index c1c6f2a8b680430e6d35b21dcc23363331cc891e..ce525ae9818acfdd1116de804eb8598480fe0d9b 100644 --- a/src/ir/value.rs +++ b/src/ir/value.rs @@ -70,7 +70,7 @@ impl Value { /// # Errors /// Returns `QueryPlannerError` when a string is not a number. pub fn number_from_str(f: &str) -> Result<Self, QueryPlannerError> { - if let Ok(d) = d128::from_str(&f.to_string()) { + if let Ok(d) = d128::from_str(f) { return Ok(Value::Number(d)); } Err(QueryPlannerError::InvalidNumber)