JVM_IR KT-50856 fix generic signature for SAM proxy function
This commit is contained in:
+13
-1
@@ -1,4 +1,6 @@
|
||||
// IGNORE_BACKEND: JVM
|
||||
// WITH_SIGNATURES
|
||||
// WITH_STDLIB
|
||||
|
||||
// FILE: indySamConversionViaProxyFun.kt.kt
|
||||
inline fun ifn() {}
|
||||
@@ -14,10 +16,15 @@ fun test() {
|
||||
|
||||
// Proxy function for arrayOf fun should be non-synthetic
|
||||
use(Sam3(::intArrayOf))
|
||||
|
||||
// Proxy function for generic fun should have valid generic signature
|
||||
use4<Map<String, String>>(::mutableMapOf)
|
||||
}
|
||||
|
||||
fun use(x: Any) {}
|
||||
|
||||
fun <U> use4(x: Sam4<U>) {}
|
||||
|
||||
// FILE: Sam1.java
|
||||
public interface Sam1 {
|
||||
String get(String x, Object y);
|
||||
@@ -31,4 +38,9 @@ public interface Sam2 {
|
||||
// FILE: Sam3.java
|
||||
public interface Sam3 {
|
||||
int[] get(int[] s);
|
||||
}
|
||||
}
|
||||
|
||||
// FILE: Sam4.java
|
||||
public interface Sam4<T> {
|
||||
T get();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user