import org.jetbrains.annotations.NotNull; class C { void f(@NotNull Object o, boolean b) { if (b) { o = null; } g(o); } void g(Object o) { } }