Github user cloud-fan commented on a diff in the pull request:

    https://github.com/apache/spark/pull/20647#discussion_r170208349
  
    --- Diff: 
sql/core/src/main/scala/org/apache/spark/sql/execution/datasources/v2/DataSourceV2Strategy.scala
 ---
    @@ -23,11 +23,11 @@ import org.apache.spark.sql.execution.SparkPlan
     
     object DataSourceV2Strategy extends Strategy {
       override def apply(plan: LogicalPlan): Seq[SparkPlan] = plan match {
    -    case relation: DataSourceV2Relation =>
    -      DataSourceV2ScanExec(relation.output, relation.reader) :: Nil
    +    case r: DataSourceV2Relation =>
    --- End diff --
    
    `relation` is called many times in the next line, renaming it to `r` can 
shorten the code below.


---

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to