Skip to content

Filter out static forwarders for Java package private methods#14662

Merged
smarter merged 1 commit intoscala:mainfrom
vasilmkd:java-package-private-forwarders
Mar 11, 2022
Merged

Filter out static forwarders for Java package private methods#14662
smarter merged 1 commit intoscala:mainfrom
vasilmkd:java-package-private-forwarders

Conversation

@vasilmkd
Copy link
Copy Markdown
Contributor

Fixes #14624.

Thank you @smarter, from the bottom of my heart.

@@ -0,0 +1,12 @@
object MyClassValue extends ClassValue[String] {
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This test isn't guaranteed to keep working since the JDK might add new public methods to ClassValue at any moment. Could you make a test with a custom .java file instead? To test separate compilation the java file needs to end with _1 and the scala file with _2 and both need to be in a subdirectory like in https://github.com/lampepfl/dotty/tree/main/tests/run/java-intersection (checkfile in https://github.com/lampepfl/dotty/blob/main/tests/run/java-intersection.check)

@vasilmkd vasilmkd requested a review from smarter March 10, 2022 22:39
Copy link
Copy Markdown
Member

@smarter smarter left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks!

@smarter smarter merged commit 895598f into scala:main Mar 11, 2022
@vasilmkd vasilmkd deleted the java-package-private-forwarders branch March 11, 2022 20:51
@Kordyjan Kordyjan added this to the 3.1.3 milestone Aug 1, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

A question about static forwarders for Java package private methods

3 participants