unknown enum constant Feature.SEALED_CLASSES

Aleksey Shipilev shade at redhat.com
Mon Sep 6 07:11:19 UTC 2021


On 9/6/21 1:40 AM, R H wrote:
> Am 01.09.2021 um 16:52 schrieb Aleksey Shipilev:
>> Weird, current jdk18 builds fine everywhere I look.
> 
> Looking at the machines I tried, I find that hard to believe :)

Lots of developers build mainline every day, I am sure the breakage like this would be noticed :) 
So, I think something is odd about your/Debian build config?

> * Boot JDK:       openjdk version "17-ea" 2021-09-14 OpenJDK Runtime
> Environment (build 17-ea+19-Debian-1) OpenJDK 64-Bit Server VM (build
> 17-ea+19-Debian-1, mixed mode, sharing) (at
> /usr/lib/jvm/java-17-openjdk-amd64)

17-ea+19 seems quite old. And sealed classes graduated out of preview feature in 17-ea+b24, and 
further cleanups done later:
   https://bugs.openjdk.java.net/browse/JDK-8260517

Current is jdk-17+35, maybe the cause is too old JDK 17 used as boot?
   https://github.com/openjdk/jdk17/releases

> In any case, how far can I go back? I think I tried older jdk17 builds, too.

Try *newer* jdk17 builds? I am able to build with latest JDK 17u nightly as boot JDK as well:
   https://builds.shipilev.net/openjdk-jdk17/

Tools summary:
* Boot JDK:       openjdk version "17-testing" 2021-09-14 OpenJDK Runtime Environment (build 
17-testing+0-builds.shipilev.net-openjdk-jdk17-b34-20210822) OpenJDK 64-Bit Server VM (build 
17-testing+0-builds.shipilev.net-openjdk-jdk17-b34-20210822, mixed mode, sharing) (at 
/home/shade/Install/jdk17u-ea)
* Toolchain:      gcc (GNU Compiler Collection)
* C Compiler:     Version 9.3.0 (at /usr/bin/gcc)
* C++ Compiler:   Version 9.3.0 (at /usr/bin/g++)

Alternatively, fall back to released JDK 16 as the boot JDK?

-- 
Thanks,
-Aleksey




More information about the build-dev mailing list