-
Notifications
You must be signed in to change notification settings - Fork 318
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
Frgaal integration in sbt #3421
Conversation
Half-working since it chokes on generated classes from annotation processor.
For reasons unknown AutoService would fail to initialize and fail to generate required builtin method classes. Hidden error message is not particularly revealing on the reason for that: ``` [error] error: Bad service configuration file, or exception thrown while constructing Processor object: javax.annotation.processing.Processor: Provider com.google.auto.service.processor.AutoServiceProcessor could not be instantiated ``` The sample records is only to demonstrate that we can now use newer Java features.
@JaroslavTulach Runtime now compiles with a sample feature from latest Java. If you are OK with this I will apply this setting to all subprojects and make it non-WIP. |
lib/scala/interpreter-dsl/src/main/java/org/enso/interpreter/dsl/MethodProcessor.java
Show resolved
Hide resolved
Bench requires jmh classes which are not available because we obviously had to limit `java.base` modules to get Frgaal to work nicely. For now, we default to good ol' javac for Benchmarks. Limiting Frgaal to runtime for now, if it plays nicely, we can expand it to other projects.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good
@JaroslavTulach do we want to switch to Java 17 GraalVM in the future? |
Updating to Frgaal 19.0.0-RC1 to give us access to latest Java features including pattern matching on `record` classes. Builds upon #3421.
Updating to Frgaal 19.0.0-RC1 to give us access to latest Java features including pattern matching on `record` classes. Builds upon #3421.
Pull Request Description
Frgaal allows to use latest Java features without requiring users to upgrade their runtime.
There is however no ready plugin for sbt to integrate with it.
This change replaces the regular local java compiler in the sbt definition.
Related to #181988063
Important Notes
This change demonstrates that we can compile shiny 16+ Java features without upgrading the requirements for the end users.
This currently migrates only runtime to Frgaal. We can eventually move other projects to that compiler as well.
For reasons unknown AutoService would fail to initialize and fail to
generate required builtin method classes.
Hidden error message is not particularly revealing on the reason for
that:
Replaced AutoService with ServiceProvider which does seem to do exactly the same thing.
Checklist
Please include the following checklist in your PR:
./run dist
and./run watch
.