e6b5cb5216
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
25 lines
486 B
Kotlin
Vendored
25 lines
486 B
Kotlin
Vendored
// !WITH_NEW_INFERENCE
|
|
// !CHECK_TYPE
|
|
// !DIAGNOSTICS: -UNUSED_PARAMETER
|
|
// FILE: A.java
|
|
|
|
public class A {
|
|
public static Out<? super CharSequence> foo() { return null; }
|
|
public static In<? extends CharSequence> bar() { return null; }
|
|
}
|
|
|
|
// FILE: main.kt
|
|
|
|
class Out<out E> {
|
|
fun x(): E = null!!
|
|
}
|
|
|
|
class In<in F> {
|
|
fun y(f: F) {}
|
|
}
|
|
|
|
fun test() {
|
|
A.foo().x() checkType { _<Any?>() }
|
|
A.bar().<!MEMBER_PROJECTED_OUT{OI}!>y<!>(<!NULL_FOR_NONNULL_TYPE{NI}!>null<!>)
|
|
}
|