Files
kotlin-fork/compiler/testData/diagnostics/tests/scopes/inheritance/nestedCompanionClassVsNestedJava.kt
T
Dmitriy Novozhilov e6b5cb5216 [TD] Update diagnostics test data due to new test runners
Update includes:
- Changing syntax of `OI/`NI` tags from `<!NI;TAG!>` to `<!TAG{NI}!>`
- Fix some incorrect directives
- Change order of diagnostics in some places
- Remove ignored diagnostics from FIR test data (previously `DIAGNOSTICS` didn't work)
- Update FIR dumps in some places and add `FIR_IDENTICAL` if needed
- Replace all JAVAC_SKIP with SKIP_JAVAC directive
2020-12-16 19:52:25 +03:00

48 lines
702 B
Kotlin
Vendored

// !LANGUAGE: -ProhibitVisibilityOfNestedClassifiersFromSupertypesOfCompanion
// FILE: 1.kt
open class A {
class Y {
fun A_Y() {}
}
companion object {
class Z {
fun A_C_Z() {}
}
}
}
// FILE: B.java
public class B extends A {
class Y {
void B_Y() {}
}
class Z {
void B_Z() {}
}
}
// FILE: C.java
public class C extends A {}
// FILE: 2.kt
class E: B() {
init {
Y().B_Y()
Y().<!UNRESOLVED_REFERENCE!>A_Y<!>()
Z().B_Z()
Z().<!UNRESOLVED_REFERENCE!>A_C_Z<!>()
}
}
class Y: C() {
init {
Y().A_Y()
<!DEPRECATED_ACCESS_BY_SHORT_NAME!>Z()<!>.A_C_Z()
}
}