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

    https://github.com/apache/spark/pull/22031#discussion_r210467721
  
    --- Diff: 
sql/catalyst/src/test/scala/org/apache/spark/sql/catalyst/expressions/HigherOrderFunctionsSuite.scala
 ---
    @@ -396,4 +396,52 @@ class HigherOrderFunctionsSuite extends SparkFunSuite 
with ExpressionEvalHelper
           map_zip_with(mbb0, mbbn, concat),
           null)
       }
    +
    +  test("ZipWith") {
    +    def zip_with(
    +        left: Expression,
    +        right: Expression,
    +        f: (Expression, Expression) => Expression): Expression = {
    +      val ArrayType(leftT, leftContainsNull) = 
left.dataType.asInstanceOf[ArrayType]
    +      val ArrayType(rightT, rightContainsNull) = 
right.dataType.asInstanceOf[ArrayType]
    +      ZipWith(left, right, createLambda(leftT, leftContainsNull, rightT, 
rightContainsNull, f))
    +    }
    +
    +    val ai0 = Literal.create(Seq(1, 2, 3), ArrayType(IntegerType, 
containsNull = false))
    +    val ai1 = Literal.create(Seq(1, 2, 3), ArrayType(IntegerType, 
containsNull = false))
    --- End diff --
    
    What's the difference between `ai0` and `ai1`?


---

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

Reply via email to