spark-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sean R. Owen (Jira)" <j...@apache.org>
Subject [jira] [Created] (SPARK-29411) Remove use of Unit companion object in favor of ()
Date Wed, 09 Oct 2019 14:26:00 GMT
Sean R. Owen created SPARK-29411:
------------------------------------

             Summary: Remove use of Unit companion object in favor of ()
                 Key: SPARK-29411
                 URL: https://issues.apache.org/jira/browse/SPARK-29411
             Project: Spark
          Issue Type: Sub-task
          Components: ML, Spark Core
    Affects Versions: 3.0.0
            Reporter: Sean R. Owen
            Assignee: Sean R. Owen


Scala 2.13 disallows use of the {{Unit}} companion object:

{code}
scala> val bar = (i:Int) => Unit
                            ^
       error: `Unit` companion object is not allowed in source; instead, use `()` for the
unit value
{code}

In these cases, where it's used to mean _the_ Unit object, just use {{()}}.



--
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


Mime
View raw message