Files
javademos/jep512/output/07-private-constructor-25-vs-27.txt
T
Claude e0cb6e83e2 Add jep512 module: compact source files and instance main methods on JDK 25 and 27
Runnable sources, broken examples and captured transcripts for the ankurm.com JEP 512 article,
including the measured launch order and a private-constructor difference between 25 and 27.

Co-Authored-By: Claude Sonnet 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01TF9JWFvJSNm6HVzswzZU5a
2026-09-24 10:32:47 +00:00

9 lines
424 B
Plaintext

$ java broken/PrivateCtor.java (OpenJDK Runtime Environment Temurin-25.0.4.1+1 (build 25.0.4.1+1-LTS))
instance main() reached through a PRIVATE zero-argument constructor
$ java broken/PrivateCtor.java (OpenJDK Runtime Environment Temurin-27+35 (build 27+35))
error: no non-private zero argument constructor found in class PrivateCtor
remove private from existing constructor or define as:
public PrivateCtor()