Skip to content

Fix the IDE always crashing due to an incorrect cast under Java 9+ #5166

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

Merged
merged 1 commit into from
Sep 26, 2018

Conversation

smarter
Copy link
Member

@smarter smarter commented Sep 26, 2018

No description provided.

Copy link
Contributor

@allanrenucci allanrenucci left a comment

Choose a reason for hiding this comment

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

LGTM but can't we fix this once and for all?

Can't we use the dotty.tools.io.ClassPath abstraction? IIUC we want to list the TASTY files in our classpath. Can't we get them with ClassPath::asClassPathStrings?

@allanrenucci allanrenucci assigned smarter and unassigned allanrenucci Sep 26, 2018
@smarter
Copy link
Member Author

smarter commented Sep 26, 2018

It's tricky, traversing all the classpaths to find the tasty files is expensive, so we'd like to cache the result, but then we need to invalidate the cache if something changes, but we don't have a good way to check if something has changed. The compromise solution for now is that zips (that is, .jar files) are considered immutable and kept in cache, whereas directories are not. I think a better solution will take some time to be developed.

@smarter smarter merged commit 71b8334 into scala:master Sep 26, 2018
@allanrenucci allanrenucci deleted the fix-ide-java9 branch September 26, 2018 15:14
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.

2 participants