Make isFromJava check work for SAM adapter extension descriptors (KT-21538)
Consider all callable descriptor in JavaClassDescriptor to be from Java. This is used to check if smart step into should be intercepted by Kotlin handler or delegated to Java. #KT-21538 Fixed
This commit is contained in:
@@ -49,4 +49,9 @@ public class MyJavaClass {
|
||||
public static class RawADerived extends RawA {
|
||||
|
||||
}
|
||||
|
||||
// Method with sam conversion for step into test
|
||||
public void other(Runnable runnable) {
|
||||
runnable.run();
|
||||
}
|
||||
}
|
||||
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
package javaSamFunction
|
||||
|
||||
import forTests.MyJavaClass
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
val klass = MyJavaClass()
|
||||
//Breakpoint!
|
||||
klass.other { /* do nothing*/ }
|
||||
}
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
LineBreakpoint created at javaSamFunction.kt:8
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
javaSamFunction.kt:8
|
||||
MyJavaClass.java:55
|
||||
resuming javaSamFunction.kt:8
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
Reference in New Issue
Block a user