public class A { 

    public static void main(String[] args) { 
        Runnable test1 = ((I)(new I() {}))::test; 
        Runnable test2 = ((new I() {}))::test; 
    } 

    interface I { 
        private void test() {} 
    } 

} 