class A { companion object { class B { } fun foo() { } } fun bar() { foo() } }