java-topology/test/langtools/tools/javac/lambda/8169091/T8169091.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
368 B
Java

/*
* @test
* @bug 8169091
* @summary Method reference T::methodName for generic type T does not compile any more
* @compile T8169091.java
*/
import java.io.Serializable;
import java.util.Comparator;
interface T8169091 {
static <T extends Comparable<? super T>> Comparator<T> comparator() {
return (Comparator<T> & Serializable)T::compareTo;
}
}