Skip to content

Conversation

@xuwei-k
Copy link
Contributor

@xuwei-k xuwei-k commented Nov 4, 2024

No description provided.

@scala-jenkins scala-jenkins added this to the 2.13.16 milestone Nov 4, 2024
@som-snytt
Copy link
Contributor

Just checking.

➜  scala git:(tweak/project-syntax) scalac -d /tmp/sandbox -Ystop-after:parser -Xlint -quickfix:any project/*.scala
project/GenerateAnyVals.scala:506: warning: [rewritten by -quickfix] procedure syntax is deprecated: instead, add `: Unit =` to explicitly declare `run`'s return type
  def run(outDir: java.io.File) {
                                ^
project/GenerateDocsData.scala:165: warning: [rewritten by -quickfix] procedure syntax is deprecated: instead, add `: Unit =` to explicitly declare `run`'s return type
  def run(outDir: File) {
                        ^
2 warnings

@som-snytt
Copy link
Contributor

diff --git a/project/GenerateFunctionConverters.scala b/project/GenerateFunctionConverters.scala
index 52e02adfbb..0a7b7c1e96 100644
--- a/project/GenerateFunctionConverters.scala
+++ b/project/GenerateFunctionConverters.scala
@@ -287,7 +287,7 @@ object GenerateFunctionConverters {
         numberedA ++= scalaTargs.map(_.toString).collect{ case An(digits) if (digits.length < 10) => digits.toInt }
         val scalafnTnames = (jfn.pTypes :+ jfn.rType).zipWithIndex.map{
           case (pt, i) if (i < jfn.pTypes.length && pt.isFinalType) || (!pt.isFinalType && jfn.pTypes.take(i).exists(_ == pt)) =>
-            val j = Iterator.from(i).dropWhile(numberedA).next
+            val j = Iterator.from(i).dropWhile(numberedA).next()
             val genericName = TypeName(s"A$j")
             numberedA += j
             evidences += ((genericName, pt.typeSymbol.name.toTypeName))

The procedure syntax gave it a steam punk vibe.

@SethTisue SethTisue added the internal not resulting in user-visible changes (build changes, tests, internal cleanups) label Nov 4, 2024
@SethTisue SethTisue merged commit 03b79e9 into scala:2.13.x Nov 4, 2024
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

internal not resulting in user-visible changes (build changes, tests, internal cleanups)

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants