How to set default JDK to always be preview features enabled?

已回答

JDK 22 has String templates which is pretty cool. In general I find the newer features of Java that are still being tested as very cool and worth always keeping enabled. Is there a way to have project setting be set to always enable preview features (and no warnings?)

0

Hello Kanishknishar,

It's not suggested to do so, as many preview features are changed or canceled in the final release, here is a working example:
https://mail.openjdk.org/pipermail/amber-spec-experts/2024-March/004010.html
The string templates will be changed a lot, so just like in this example, we didn't have a plan to let the user select the preview by default, some old versions' preview features are even removed from the latest IDEA as they are abandoned or become a stable feature:

https://imgur.com/a/kmeIVsV

0

请先登录再写评论。