[FIR TEST]: add test with Map.Entry-based J/K hierarchy
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
// FILE: Test.java
|
||||
|
||||
import java.lang.*;
|
||||
import java.util.*;
|
||||
|
||||
public class Test {
|
||||
public static class MapEntryImpl implements Map.Entry<String, String> {
|
||||
public String getKey() { return null; }
|
||||
public String getValue() { return null; }
|
||||
public String setValue(String s) { return null; }
|
||||
}
|
||||
}
|
||||
|
||||
// FILE: main.kt
|
||||
|
||||
class MyMapEntry : Test.MapEntryImpl()
|
||||
|
||||
fun test() {
|
||||
val b = MyMapEntry()
|
||||
b.key
|
||||
b.value
|
||||
b.setValue(null)
|
||||
}
|
||||
@@ -0,0 +1,13 @@
|
||||
FILE: main.kt
|
||||
public final class MyMapEntry : R|Test.MapEntryImpl| {
|
||||
public constructor(): R|MyMapEntry| {
|
||||
super<R|Test.MapEntryImpl|>()
|
||||
}
|
||||
|
||||
}
|
||||
public final fun test(): R|kotlin/Unit| {
|
||||
lval b: R|MyMapEntry| = R|/MyMapEntry.MyMapEntry|()
|
||||
R|<local>/b|.R|/Test.MapEntryImpl.key|
|
||||
R|<local>/b|.R|/Test.MapEntryImpl.value|
|
||||
R|<local>/b|.R|/Test.MapEntryImpl.setValue|(Null(null))
|
||||
}
|
||||
Generated
+5
@@ -489,6 +489,11 @@ public class FirDiagnosticsWithStdlibTestGenerated extends AbstractFirDiagnostic
|
||||
runTest("compiler/fir/resolve/testData/resolve/stdlib/j+k/LoggerInstance.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("MapEntry.kt")
|
||||
public void testMapEntry() throws Exception {
|
||||
runTest("compiler/fir/resolve/testData/resolve/stdlib/j+k/MapEntry.kt");
|
||||
}
|
||||
|
||||
@TestMetadata("MyException.kt")
|
||||
public void testMyException() throws Exception {
|
||||
runTest("compiler/fir/resolve/testData/resolve/stdlib/j+k/MyException.kt");
|
||||
|
||||
Reference in New Issue
Block a user