class Conditional { void m(Object p, boolean b) { int a = b ? null : ((Getter) p).get(); int a1 = b ? null : Conditional.f(); int a2 = b ? null : 1; int a3 = b ? null : f1(); int a4 = b ? null : f2(); int a5 = b ? null : Conditional.f2(); Long someNum = b ? getNum(5L) : 0; } private static T getNum(T num) { return num; } private static T f() { return null; } private static int f1() { return 1; } private static S f2() { return null; } } interface Getter { A get(); }