Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Scala 3.3.1-RC1 (enable TastyTest on JDK 21) #10409

Merged
merged 1 commit into from
May 26, 2023

Conversation

SethTisue
Copy link
Member

@SethTisue SethTisue commented May 25, 2023

this should work on JDK 21 now that scala/scala3#17536 has been merged?

@scala-jenkins scala-jenkins added this to the 2.13.12 milestone May 25, 2023
@SethTisue SethTisue added the internal not resulting in user-visible changes (build changes, tests, internal cleanups) label May 25, 2023
@SethTisue SethTisue modified the milestones: 2.13.12, 2.13.11 May 25, 2023
@SethTisue
Copy link
Member Author

SethTisue commented May 25, 2023

@bishabosha this fails (not just on JDK 21) with:

ERROR: /Users/tisue/scala.213/test/tasty/neg/src-2/TestSaferExceptions_fail.scala failed, unexpected output.
--- check
+++ output
@@ -1,2 +1,2 @@
-TestSaferExceptions_fail.scala:5: error: Unsupported Scala 3 erased context function type in bounds of type mayThrow: erased tastytest.SaferExceptions.CanThrowCapability[E] ?=> A; found in object tastytest.SaferExceptions.
+TestSaferExceptions_fail.scala:5: error: Unsupported Scala 3 erased value x$1; found in method apply in  tastytest.SaferExceptions.<refinement>.
   def test = SaferExceptions.safeDiv(1, 0) // error
ERROR: /Users/tisue/scala.213/test/tasty/neg/src-2/TestErasedTypes_fail.scala failed, unexpected output.
--- check
+++ output
@@ -1,7 +1,1 @@
-TestErasedTypes_fail.scala:6: error: Unsupported Scala 3 erased modifier in refinement of type F; found in class tastytest.ErasedTypes.Bar.
-  def test1 = new Bar[Foo]
-                  ^
-TestErasedTypes_fail.scala:7: error: Unsupported Scala 3 erased modifier in refinement of type F; found in class tastytest.ErasedTypes.Baz.
-  def test2 = new Baz[Foo]
-                  ^
 TestErasedTypes_fail.scala:9: error: Unsupported Scala 3 erased value x; found in method foo1 in trait tastytest.ErasedTypes.Foo.
@@ -15,2 +9,2 @@
                                    ^
-5 errors
+3 errors

can you explain what's going here? is this a concern for the 2.13.11 release? (ideally the 2.13.11 TASTy reader would work with any 3.3.x release, not just 3.3.0 specifically?)

is this actually a progression, by any chance? an expected-to-fail test that doesn't fail as much anymore and that's actually good?

provisionally marking as "prio:blocker", at least until we understand it better

@SethTisue SethTisue added the prio:blocker release blocker (used only by core team, only near release time) label May 25, 2023
@SethTisue SethTisue requested a review from bishabosha May 25, 2023 21:18
@bishabosha
Copy link
Member

bishabosha commented May 25, 2023

The encoding of erased parameters changed in 3.3.x since I first did the tasty port I guess?

So yeah the test is expected to fail, now it fails with a different message, but still expected. This error shouldn't be so common as erased is an experimental feature anyway - updating the check file should be all that's needed (/test/tasty/neg/src-2/TestSaferExceptions.check)

I guess someone could attempt to make a prettier error message than found in method apply in tastytest.SaferExceptions.<refinement>.

Also the error message could be updated to suggest the project maintainer update the check file (and print its path)

this should work on JDK 21 now that scala/scala3#17536
has been merged
@SethTisue SethTisue marked this pull request as ready for review May 25, 2023 21:50
@SethTisue SethTisue removed the prio:blocker release blocker (used only by core team, only near release time) label May 25, 2023
@SethTisue SethTisue assigned SethTisue and unassigned bishabosha May 25, 2023
@SethTisue SethTisue merged commit fd209dc into scala:2.13.x May 26, 2023
@SethTisue SethTisue deleted the scala-3.3.1-RC1 branch May 26, 2023 18:16
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.

3 participants