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

    https://github.com/apache/spark/pull/19865#discussion_r156243726
  
    --- Diff: 
sql/catalyst/src/main/scala/org/apache/spark/sql/catalyst/expressions/codegen/CodeGenerator.scala
 ---
    @@ -842,7 +856,10 @@ class CodegenContext {
           blocks.head
         } else {
           val func = freshName(funcName)
    -      val argString = arguments.map { case (t, name) => s"$t $name" 
}.mkString(", ")
    +      val argString = arguments.map { case (t, name) =>
    +        assert(!isDeclaredMutableState(name),
    --- End diff --
    
    I'm neutral about this pr though, I feel this is not the best place for 
this assertion cuz this is not only the place where the suggested case happens, 
e.g., my pr splits aggregate functions in `HashAggregate`


---

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

Reply via email to