Introduce the fragment compiler backend to the debugger infrastructure

This commit is contained in:
Nikita Nazarov
2021-06-15 22:55:59 +03:00
parent aa47191de4
commit 7e44cddbab
226 changed files with 3140 additions and 80 deletions
@@ -0,0 +1,11 @@
package color
import java.awt.*
fun main(args: Array<String>) {
//Breakpoint!
args.size
}
// EXPRESSION: Color.red
// RESULT: instance of java.awt.Color(id=ID): Ljava/awt/Color;
@@ -0,0 +1,8 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
// IGNORE_BACKEND: JVM_WITH_OLD_EVALUATOR, JVM_IR_WITH_OLD_EVALUATOR
LineBreakpoint created at color.kt:7
Run Java
Connected to the target VM
color.kt:7
Disconnected from the target VM
Process finished with exit code 0
@@ -0,0 +1,17 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at ceLocalClassMembers.kt:19
Run Java
Connected to the target VM
ceLocalClassMembers.kt:19
Compile bytecode for class MyClass {
fun test() = publicFun() + publicVal + protectedFun() + protectedVal + privateFun() + privateFun()
}
val a = MyClass()
a.test()
// RESULT: 6: I
Disconnected from the target VM
Process finished with exit code 0
@@ -0,0 +1,14 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at ceMembers.kt:19
Run Java
Connected to the target VM
ceMembers.kt:19
Compile bytecode for foo { publicFun() }
Compile bytecode for foo { publicVal }
Compile bytecode for foo { protectedFun() }
Compile bytecode for foo { protectedVal }
Compile bytecode for foo { privateFun() }
Compile bytecode for foo { privateVal }
Disconnected from the target VM
Process finished with exit code 0
@@ -0,0 +1,14 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at ceSuperAccess.kt:20
Run Java
Connected to the target VM
ceSuperAccess.kt:20
Compile bytecode for foo { publicFun() }
Compile bytecode for foo { publicVal }
Compile bytecode for foo { protectedFun() }
Compile bytecode for foo { protectedVal }
Compile bytecode for foo { privateFun() }
Compile bytecode for foo { privateVal }
Disconnected from the target VM
Process finished with exit code 0
@@ -0,0 +1,11 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at capturedReceiverName.kt:22
Run Java
Connected to the target VM
capturedReceiverName.kt:22
Compile bytecode for character
capturedReceiverName.kt:22
Disconnected from the target VM
Process finished with exit code 0
OK
@@ -0,0 +1,9 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at localFunctionCapturedLocalVariable.kt:7
Run Java
Connected to the target VM
localFunctionCapturedLocalVariable.kt:7
Compile bytecode for a
Disconnected from the target VM
Process finished with exit code 0
@@ -0,0 +1,8 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at suspendCalls.kt:5
Run Java
Connected to the target VM
suspendCalls.kt:5
Disconnected from the target VM
Process finished with exit code 0