andygrove commented on code in PR #3236:
URL: https://github.com/apache/datafusion-comet/pull/3236#discussion_r2717790929
##########
native/core/src/execution/jni_api.rs:
##########
@@ -503,12 +503,7 @@ pub unsafe extern "system" fn
Java_org_apache_comet_Native_executePlan(
let task_ctx = exec_context.session_ctx.task_ctx();
// Each Comet native execution corresponds to a single Spark
partition,
// so we should always execute partition 0.
- let stream = exec_context
- .root_op
- .as_ref()
- .unwrap()
- .native_plan
- .execute(0, task_ctx)?;
+ let stream = root_op.native_plan.execute(0, task_ctx)?;
Review Comment:
clippy fix for Rust 1.93.0
##########
native/core/src/execution/jni_api.rs:
##########
@@ -619,8 +614,7 @@ pub extern "system" fn
Java_org_apache_comet_Native_releasePlan(
/// Updates the metrics of the query plan.
fn update_metrics(env: &mut JNIEnv, exec_context: &mut ExecutionContext) ->
CometResult<()> {
- if exec_context.root_op.is_some() {
- let native_query = exec_context.root_op.as_ref().unwrap();
+ if let Some(native_query) = &exec_context.root_op {
Review Comment:
clippy fix for Rust 1.93.0
##########
native/core/src/parquet/schema_adapter.rs:
##########
@@ -209,10 +209,9 @@ impl SchemaMapper for SchemaMapping {
// If this field only exists in the table, and not in the
file, then we need to
// populate a default value for it.
|| {
- if self.default_values.is_some() {
+ if let Some(default_values) = &self.default_values {
Review Comment:
clippy fix for Rust 1.93.0
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]