You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@spark.apache.org by "Apache Spark (Jira)" <ji...@apache.org> on 2021/08/12 12:04:00 UTC
[jira] [Commented] (SPARK-36495) Use Type match to simplify
CatalystTypeConverter.toCatalyst
[ https://issues.apache.org/jira/browse/SPARK-36495?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17398029#comment-17398029 ]
Apache Spark commented on SPARK-36495:
--------------------------------------
User 'LuciferYang' has created a pull request for this issue:
https://github.com/apache/spark/pull/33722
> Use Type match to simplify CatalystTypeConverter.toCatalyst
> -----------------------------------------------------------
>
> Key: SPARK-36495
> URL: https://issues.apache.org/jira/browse/SPARK-36495
> Project: Spark
> Issue Type: Improvement
> Components: SQL
> Affects Versions: 3.3.0
> Reporter: Yang Jie
> Priority: Trivial
>
> CatalystTypeConverter.toCatalyst uses the following methods for type conversion
> {code:java}
> if (maybeScalaValue.isInstanceOf[Option[ScalaInputType]]) {
> val opt = maybeScalaValue.asInstanceOf[Option[ScalaInputType]]
> {code}
>
> can use Type match to simplify this pattern
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org