Skip to content

fix [javalib]: BaseStream & its split/iterators are now type invariant #3949

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

Conversation

LeeTibbert
Copy link
Contributor

@LeeTibbert LeeTibbert commented Jun 5, 2024

Fix #3948

Make several javalib BaseStream declarations invariant.

This removes a group of quirks from the set of them that javalib developers
need to know.

The change should not be visible outside of the Scala Native build.

This change will and has been exercised by some Work-in-Progress changes to
javalib Files#walk, Files#find, and Files#walkFileTree.

@LeeTibbert
Copy link
Contributor Author

LeeTibbert commented Jun 5, 2024

The Windows error looks like it is not exactly Issue #3944, but closely related to it. waitFor() & invalid handle are
implicated (but not this PR):

// lightly edited to improve readability by removing ANSI control sequences. See original log for primary source.

2024-06-05T03:39:00.7555106Z error Test org.scalanative.testsuite.javalib.lang.RuntimeTest execCommand failed: java.nio.file.WindowsException$$anon$1 Failed to wait on proces handle - The handle is invalid. (6), took 0.017 sec
2024-06-05T03:39:00.7572746Z error at java.nio.file.WindowsException$.apply()
2024-06-05T03:39:00.7608312Z error at java.nio.file.WindowsException$.apply()    at java.lang.process.WindowsProcess.hasFinished$1()
2024-06-05T03:39:00.7614023Z error  at java.lang.process.WindowsProcess.waitFor()
2024-06-05T03:39:00.7616031Z error  at org.scalanative.testsuite.javalib.lang.RuntimeTest.execCommand

@WojciechMazur WojciechMazur merged commit 8b1359c into scala-native:main Jun 13, 2024
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.

several covariant javalib BaseStream declarations should be invariant.
2 participants