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 2022/01/31 05:16:00 UTC
[jira] [Commented] (SPARK-38076) Remove redundant null-check is covered by further condition
[ https://issues.apache.org/jira/browse/SPARK-38076?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17484507#comment-17484507 ]
Apache Spark commented on SPARK-38076:
--------------------------------------
User 'LuciferYang' has created a pull request for this issue:
https://github.com/apache/spark/pull/35369
> Remove redundant null-check is covered by further condition
> -----------------------------------------------------------
>
> Key: SPARK-38076
> URL: https://issues.apache.org/jira/browse/SPARK-38076
> Project: Spark
> Issue Type: Improvement
> Components: Spark Core
> Affects Versions: 3.3.0
> Reporter: Yang Jie
> Priority: Minor
>
> There are many code pattern as follows:
> {code:java}
> obj != null && obj instanceof SomeClass {code}
> the null-check is redundant as instanceof operator implies non-nullity.
--
This message was sent by Atlassian Jira
(v8.20.1#820001)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@spark.apache.org
For additional commands, e-mail: issues-help@spark.apache.org