class Bug { interface Function { public R apply(T t); static Function identity() { return k -> k; } } interface IFunction extends Function { static void a() { Function identity = identity(); } } public void foo() { Function f = Function.identity(); Function g = f.identity(); Function h = IFunction.identity(); } } class StaticMethodInterfaceExample { interface X {} interface MyInterface { static void staticMethod() {} } static class MyImplementation implements MyInterface { } public static class Usage { public void doStuff() { T.staticMethod(); } public void doStuff1() { T.staticMethod(); } public void doStuff2() { T.staticMethod(); } public void doStuff3() { T.staticMethod(); } } }