Files
kotlin-fork/compiler/testData/diagnostics/tests/testWithModifiedMockJdk/notConsideredMethod.fir.kt
T
2021-07-08 18:13:47 +03:00

14 lines
474 B
Kotlin
Vendored

// !JDK_KIND: MODIFIED_MOCK_JDK
// !CHECK_TYPE
interface A : MutableCollection<String> {
// Override of deprecated function could be marked as deprecated too
<!NOTHING_TO_OVERRIDE!>override<!> fun nonExistingMethod(x: String) = ""
}
fun foo(x: MutableCollection<Int>, y: Collection<String>, z: A) {
x.<!UNRESOLVED_REFERENCE!>nonExistingMethod<!>(1).checkType { _<String>() }
y.<!UNRESOLVED_REFERENCE!>nonExistingMethod<!>("")
z.nonExistingMethod("")
}