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

    https://github.com/apache/spark/pull/22732#discussion_r225804995
  
    --- Diff: 
sql/core/src/main/scala/org/apache/spark/sql/expressions/UserDefinedFunction.scala
 ---
    @@ -81,11 +81,11 @@ case class UserDefinedFunction protected[sql] (
           f,
           dataType,
           exprs.map(_.expr),
    +      nullableTypes.map(_.map(!_)).getOrElse(exprs.map(_ => false)),
    --- End diff --
    
    If we can't get the type information at compile time(e.g. `(a: Any) => 
xxx`), I don't think `ScalaReflection.getParameterTypes` can get something 
useful at runtime. For this case we won't add null check anyway, so I think 
there is no behavior change.


---

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

Reply via email to