song fengfei created SPARK-20095:
------------------------------------

             Summary: A code bug in CodegenContext.withSubExprEliminationExprs
                 Key: SPARK-20095
                 URL: https://issues.apache.org/jira/browse/SPARK-20095
             Project: Spark
          Issue Type: Bug
          Components: SQL
    Affects Versions: 2.1.0
            Reporter: song fengfei
            Priority: Minor


In the function:CodegenContext.withSubExprEliminationExprs...{
  val oldsubExprEliminationExprs = subExprEliminationExprs
   subExprEliminationExprs.clear
  ...
// Restore previous subExprEliminationExprs
    subExprEliminationExprs.clear
    oldsubExprEliminationExprs.foreach(subExprEliminationExprs += _)
}
it seems that the oldsubExprEliminationExprs  and subExprEliminationExprs are 
the same instance,after the second subExprEliminationExprs.clear ,the 
oldsubExprEliminationExprs is also cleared,so,the  previous 
subExprEliminationExprs in CodegenContext will not be  Restored.
Is it a bug?



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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

Reply via email to