java-topology/test/langtools/tools/javac/lambda/methodReference/MethodRefStuckParenthesized.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

27 lines
499 B
Java

/*
* @test /nodynamiccopyright/
* @bug 8203679
* @summary This is a negative regression test for an AssertionError in DeferredAttr.
* @compile/fail/ref=MethodRefStuckParenthesized.out -XDrawDiagnostics MethodRefStuckParenthesized.java
*/
public abstract class MethodRefStuckParenthesized {
interface I {
String v();
}
interface J {
String v();
}
abstract String v();
abstract void f(I v);
abstract <X extends J> J g(X x);
void test() {
f(g((this::v)));
}
}