Uploaded image for project: 'Spark'
  1. Spark
  2. SPARK-25075 Build and test Spark against Scala 2.13
  3. SPARK-29291

Remove use of procedure-like method definition for 2.13

    XMLWordPrintableJSON

Details

    • Sub-task
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 3.0.0
    • 3.0.0
    • Build, Spark Core
    • None

    Description

      Scala 2.13 warns where procedure-like syntax is used to define methods:

      [WARNING] [Warn] /Users/seanowen/Documents/spark_2.13/core/src/main/scala/org/apache/spark/ContextCleaner.scala:74: procedure syntax is deprecated: instead, add `: Unit =` to explicitly declare `run`'s return type
      ...
      

      There are a lot of them, but it's easy to fix.

      def foo(): Unit = { }
      

      not

      def foo() { }
      

      Attachments

        Issue Links

          Activity

            People

              srowen Sean R. Owen
              srowen Sean R. Owen
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: