-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Include a test for selective dotty bootstrap #1274
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
Comments
I'm looking at this issue, just had a discussion with @DarkDimius and he cleared my confusion about the Conceptually, the compiler and program do not share
In the program, by default it should NOT be able to use However, with For this task:
|
I just checked settings for running JUnit tests, e.g. However, when I run the compiler from command line without
I'm investigating further. |
I figured it out by printing The unexpected behaviuor is due to the fact that:
I believe this design is due to various engineering considerations, and I think it's OK to keep it as it is. However, to address potential side effects of the above approach (user want to use a different version of default lib) as well as easily fix this issue, I propose a simple change in class resolution:
With this change, we only need to add a JUnit test with the option What do you think of this change, @odersky @DarkDimius ? |
Junit test are run in forked jvm with environment constructed by hand in On 29 July 2016 11:57:11 liu fengyun [email protected] wrote:
|
This would be a nice fist step. But be aware there still may be bugs that would be either hidden or triggered by the fact that multiple versions of the same class are present on the ClassPath. In particular there may be fun interactions with name-mangling of inner classes. I'd propose to have a custom option, that prohibits loading Scala2 compiled classes that aren't in the whitelist. The whitelist could for example only include classes inside |
Thanks a lot for your comments, @DarkDimius . I just pushed a commit to make the simplest change and see how it works out. Note that previously we already have duplicate class files in the path when running |
fix #1274: test for dotty bootstrap based on tasty
Uh oh!
There was an error while loading. Please reload this page.
I have been running the script below locally to verify that bootstrap using Tasty works. It first compiles everything, then compiles each subdirectory individually, using Tasty to access info from other directories. Getting this to work took a while, so it would be good to have a test that verifies we can still do this.
Can someone with more test-foo than I give it a stab? Here's the (tcsh) script I was using (run it from
dotty/bin
):The text was updated successfully, but these errors were encountered: