GitHub user hvanhovell opened a pull request:

    https://github.com/apache/spark/pull/16041

    [SPARK-18058][SQL][TRIVIAL] Use dataType.sameResult(...) instead equality 
on asNullable datatypes

    ## What changes were proposed in this pull request?
    This is absolutely minor. PR https://github.com/apache/spark/pull/15595 
uses `dt1.asNullable == dt2.asNullable` expressions in a few places. It is 
however more efficient to call `dt1.sameType(dt2)`. I have replaced every 
instance of the first pattern with the second pattern (3/5 were introduced by 
#15595).
    
    ## How was this patch tested?
    Existing tests.


You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/hvanhovell/spark SPARK-18058

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/spark/pull/16041.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #16041
    
----
commit 37b67603b29d99987163798a0324005c97da2a9a
Author: Herman van Hovell <[email protected]>
Date:   2016-11-28T16:34:51Z

    Replace dt1.asNullable == dt2.asNullable with dt1.sameResult(dt2).

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

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

Reply via email to