Github user ueshin commented on a diff in the pull request:

    https://github.com/apache/spark/pull/15480#discussion_r86504407
  
    --- Diff: 
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/codegen/CodeGenerator.scala
 ---
    @@ -537,7 +537,6 @@ class CodegenContext {
           val funcCode: String =
             s"""
               public int $compareFunc(InternalRow a, InternalRow b) {
    -            InternalRow i = null;
    --- End diff --
    
    I think `GenerateOrdering.genComparisons()` is expected to generate a PART 
of comparison method. If the declaration of the variable `i` is in the part, we 
can't use `GenerateOrdering.genComparisons()` twice or more for the same method.
    Declaration of unused variable will not be a problem.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to