public class Main { class B {} public void someMethod() { B b = new B<>(); } }