Update Intellij project files for Java17#634
Conversation
.idea/misc.xml
Outdated
| <item index="3" class="java.lang.String" itemvalue="javax.annotation.Nullable" /> | ||
| <item index="4" class="java.lang.String" itemvalue="android.support.annotation.Nullable" /> | ||
| <item index="5" class="java.lang.String" itemvalue="androidx.annotation.Nullable" /> | ||
| <item index="6" class="java.lang.String" itemvalue="androidx.annotation.RecentlyNullable" /> |
There was a problem hiding this comment.
JavaSMT does not depend on the package androidx. We might want to remove these line.
There was a problem hiding this comment.
Hello Karlheinz,
thanks for the hint! I've now removed some of the nullable annotations we're not using. For the rest the "remove" button is greyed out in the GUI, maybe because they're used by one of our dependencies?
From what I understand, this is just a list of annotations that Intellij will recognize for its own nullable analysis. So having some additional ones in there shouldn't cause too many problems
kfriedberger
left a comment
There was a problem hiding this comment.
The entry for JDK is a good catch. CPAchecker does not use the JDK-entry, see https://github.com/sosy-lab/cpachecker/blob/main/.idea/ , and seems to work well, too.
Overall, if that helps someone, ok for me.
|
I reworked the IntelliJ configs of CPAchecker last year and can take a look or even do it myself quickly on the bases of CPAchecker. But we can't just re-use them from other projects, as the setup needs to be specific. (It took me quite a while to understand how this works, as the documentation of IntelliJ IDEA was very incomplete on several issues. The behavior of a IntelliJ configuration that is only partially correct, as every IntelliJ user knowns, is that things (e.g. dependencies) are not automatically updated or pulled, licenses are removed/added in config files all the time randomly, the configs are changed constantly by IntelliJ despite settings that it should not etc.) |
|
@daniel-raffler Review here instead of the code: In CPAchecker i used Ant to get all information about classpaths etc. by adding the flag You can get the classpath info by searching for the string If we want to do this properly, we need to define modules for all solvers and their dependencies. Since i don't know how this works if we can't load a solver, we need to test this thoroughly! Running Ant in verbose mode seems to indicate a problem with Further, a default copyright header can be defined in Also, we can get rid of many edits of IntelliJ IDEA on its own configuration files by extracting the licenses in them into a file, for example like this. Also, we should define which nullness annotations we actually want to use. This is defined in our Ant configs and IntelliJ should not diverge. Example from CPAchecker here. This can be set in the settings (no need to touch the config code directly). I also don't see a reason to load all annotation frameworks. It is sufficient to load only the ones we need (see lines following this). We should set all flags that stop IntelliJ from editing itself all the time. That's not perfect, but helps a lot (or i did not find all flags? But it is a common problem reported online, so i don't know....). I don't remember where you can set this in the settings, but the config change in CPAchecker can be seen here for example. I don't see a reason to change the compiler or compiler settings in JavaSMT. That was only needed in CPAchecker due to problems that are not present in JavaSMT! You can find the MR from CPAchecker here. Some things are not optimal there, and some are not applicable for JavaSMT. E.g. i used a single module dependency for CPAchecker, but JavaSMT should define multiple. |
|
@baierd Thanks for the summary! I've already split off the license headers and cleaned up the Whenever possible I also included the
Hmm.. I'm not sure, but shouldn't Ivy already have taken care of these conflicts? |
We need to include 'contrib' here to get the sources/docs for the solver, and not just the java-smt yices backend
…to the project configuration
Hello,
this PR tries to update the Intellij project files for Java17. It's a draft for now, as I'm not sure if more changes that will be needed
@baierd
i believe you're also using Intellij? Could you please give it a try to see if it's working?