java-topology/test/langtools/tools/javac/T8255968/T8255968_4.java
russell@unturf.com 0a580b313d undefect. CWE-407 — 63 sites patched across 27 ecosystems
Authors: russell@unturf.com · brackishbert@gmail.com · foxhop.net · TimeHexOn.com

Patches, unit tests, benchmarks, whitepaper, and outreach briefs.
Public domain — no copyright claimed. Use freely.
2026-03-26 17:11:57 -04:00

15 lines
467 B
Java

/*
* @test /nodynamiccopyright/
* @bug 8255968
* @summary Confusing error message for inaccessible constructor
* @run compile/fail/ref=T8255968_4.out -XDrawDiagnostics T8255968_4.java
*/
class T8255968_4 {
T8255968_4_Test c = new T8255968_4_Test(0);
}
class T8255968_4_Test {
T8255968_4_Test(String x) {} // If this method is private, compiler will output the same error message.
private T8255968_4_Test(int x) {} // This method is at the end.
}