You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@pekko.apache.org by "He-Pin (via GitHub)" <gi...@apache.org> on 2026/06/18 11:04:09 UTC

[PR] fix: remove -Yfuture-lazy-vals for Scala 3.9+ [pekko-grpc]

He-Pin opened a new pull request, #732:
URL: https://github.com/apache/pekko-grpc/pull/732

   ### Motivation
   Scala 3.9.0-RC1 removed the `-Yfuture-lazy-vals` compiler option (the behavior is now the default). Under `-Werror`, the "bad option" warning becomes a compilation error.
   
   ### Modification
   Conditionally include `-Yfuture-lazy-vals` only for Scala 3.x where minor version < 9, using `CrossVersion.partialVersion` check.
   
   ### Result
   pekko-grpc codegen module compiles cleanly with Scala 3.9.0-RC1.
   
   ### Tests
   - `sbt "++3.9.0-RC1!; codegen/compile"` passes
   
   ### References
   None - Scala 3.9 forward compatibility


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@pekko.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@pekko.apache.org
For additional commands, e-mail: notifications-help@pekko.apache.org


Re: [PR] fix: remove -Yfuture-lazy-vals for Scala 3.9+ [pekko-grpc]

Posted by "mkurz (via GitHub)" <gi...@apache.org>.
mkurz commented on code in PR #732:
URL: https://github.com/apache/pekko-grpc/pull/732#discussion_r3436080255


##########
project/Common.scala:
##########
@@ -54,14 +54,9 @@ object Common extends AutoPlugin {
            "-encoding",
            "UTF-8")
        else
-         Seq(
-           "-unchecked",
-           "-deprecation",
-           "-Werror",
-           "-Wunused:imports",
-           "-Yfuture-lazy-vals",
-           "-encoding",
-           "UTF-8")),
+         Seq("-unchecked", "-deprecation", "-Werror", "-Wunused:imports", "-encoding", "UTF-8") ++
+         (if (CrossVersion.partialVersion(scalaVersion.value).exists(_._2 < 9)) Seq("-Yfuture-lazy-vals")

Review Comment:
   ah sorry i am wrong, foget it



##########
project/Common.scala:
##########
@@ -54,14 +54,9 @@ object Common extends AutoPlugin {
            "-encoding",
            "UTF-8")
        else
-         Seq(
-           "-unchecked",
-           "-deprecation",
-           "-Werror",
-           "-Wunused:imports",
-           "-Yfuture-lazy-vals",
-           "-encoding",
-           "UTF-8")),
+         Seq("-unchecked", "-deprecation", "-Werror", "-Wunused:imports", "-encoding", "UTF-8") ++
+         (if (CrossVersion.partialVersion(scalaVersion.value).exists(_._2 < 9)) Seq("-Yfuture-lazy-vals")

Review Comment:
   ah sorry i am wrong, forget it



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@pekko.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@pekko.apache.org
For additional commands, e-mail: notifications-help@pekko.apache.org


Re: [PR] fix: remove -Yfuture-lazy-vals for Scala 3.9+ [pekko-grpc]

Posted by "mkurz (via GitHub)" <gi...@apache.org>.
mkurz commented on code in PR #732:
URL: https://github.com/apache/pekko-grpc/pull/732#discussion_r3436071365


##########
project/Common.scala:
##########
@@ -54,14 +54,9 @@ object Common extends AutoPlugin {
            "-encoding",
            "UTF-8")
        else
-         Seq(
-           "-unchecked",
-           "-deprecation",
-           "-Werror",
-           "-Wunused:imports",
-           "-Yfuture-lazy-vals",
-           "-encoding",
-           "UTF-8")),
+         Seq("-unchecked", "-deprecation", "-Werror", "-Wunused:imports", "-encoding", "UTF-8") ++
+         (if (CrossVersion.partialVersion(scalaVersion.value).exists(_._2 < 9)) Seq("-Yfuture-lazy-vals")

Review Comment:
   what if Scala 3.9.10 is used? that also matches `< 9` for minor version



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@pekko.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@pekko.apache.org
For additional commands, e-mail: notifications-help@pekko.apache.org


Re: [PR] fix: remove -Yfuture-lazy-vals for Scala 3.9+ [pekko-grpc]

Posted by "He-Pin (via GitHub)" <gi...@apache.org>.
He-Pin merged PR #732:
URL: https://github.com/apache/pekko-grpc/pull/732


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@pekko.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@pekko.apache.org
For additional commands, e-mail: notifications-help@pekko.apache.org