import a.* fun main(args: Array) { val declaredMethod = javaClass().getDeclaredMethod("foo", javaClass>()) val genericString = declaredMethod.toGenericString() if (genericString != "public abstract a.Rec a.Super.foo(a.Rec)") throw AssertionError(genericString) } fun test(s: Super, p: Rec<*, *>) { s.foo(p).t().t().t() }