Move debugger test data to the new location
This commit is contained in:
+14
@@ -0,0 +1,14 @@
|
||||
// Test evaluate expression for default package
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
//Breakpoint!
|
||||
args.size
|
||||
}
|
||||
|
||||
class Test(val a: Int)
|
||||
|
||||
// EXPRESSION: 1 + 1
|
||||
// RESULT: 2: I
|
||||
|
||||
// EXPRESSION: Test(1).a
|
||||
// RESULT: 1: I
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
LineBreakpoint created at .kt.kt:5
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
.kt.kt:5
|
||||
Compile bytecode for 1 + 1
|
||||
Compile bytecode for Test(1).a
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
Vendored
+9
@@ -0,0 +1,9 @@
|
||||
package abstractFunCall
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
//Breakpoint!
|
||||
args.size
|
||||
}
|
||||
|
||||
// EXPRESSION: (1 as java.lang.Number).intValue()
|
||||
// RESULT: 1: I
|
||||
Vendored
+8
@@ -0,0 +1,8 @@
|
||||
LineBreakpoint created at abstractFunCall.kt:5
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
abstractFunCall.kt:5
|
||||
Compile bytecode for (1 as java.lang.Number).intValue()
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
package accessToOverridenPropertyWithBackingField
|
||||
|
||||
open class B1 {
|
||||
val prop = "OK"
|
||||
}
|
||||
|
||||
class D1: B1()
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
val d = D1()
|
||||
//Breakpoint!
|
||||
d.prop // <-- breakpoint here
|
||||
}
|
||||
|
||||
// EXPRESSION: d.prop
|
||||
// RESULT: "OK": Ljava/lang/String;
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
LineBreakpoint created at accessToOverridenPropertyWithBackingField.kt:12
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
accessToOverridenPropertyWithBackingField.kt:12
|
||||
Compile bytecode for d.prop
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
Vendored
+15
@@ -0,0 +1,15 @@
|
||||
package annotationValue
|
||||
|
||||
annotation class Anno(val value: String)
|
||||
|
||||
@Anno("abc")
|
||||
class SomeClass
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
//Breakpoint!
|
||||
val a = 5
|
||||
}
|
||||
|
||||
// EXPRESSION: (SomeClass::class.java.annotations[0] as Anno).value
|
||||
// RESULT: "abc": Ljava/lang/String;
|
||||
|
||||
Vendored
+8
@@ -0,0 +1,8 @@
|
||||
LineBreakpoint created at annotationValue.kt:10
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
annotationValue.kt:10
|
||||
Compile bytecode for (SomeClass::class.java.annotations[0] as Anno).value
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
Vendored
+19
@@ -0,0 +1,19 @@
|
||||
package anonymousObjects
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
val a = object: AbstractClass(1) {}
|
||||
a.test(1)
|
||||
}
|
||||
|
||||
abstract class AbstractClass(val i: Int) {
|
||||
fun test(i: Int): Int {
|
||||
//Breakpoint!
|
||||
return i
|
||||
}
|
||||
}
|
||||
|
||||
// EXPRESSION: test(2)
|
||||
// RESULT: 2: I
|
||||
|
||||
// EXPRESSION: i
|
||||
// RESULT: 1: I
|
||||
Vendored
+9
@@ -0,0 +1,9 @@
|
||||
LineBreakpoint created at anonymousObjects.kt:11
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
anonymousObjects.kt:11
|
||||
Compile bytecode for test(2)
|
||||
Compile bytecode for i
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+15
@@ -0,0 +1,15 @@
|
||||
package arrayMethods
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
//Breakpoint!
|
||||
val a = 5
|
||||
}
|
||||
|
||||
// EXPRESSION: args.toString().length > 0
|
||||
// RESULT: 1: Z
|
||||
|
||||
// EXPRESSION: args.hashCode() and 0
|
||||
// RESULT: 0: I
|
||||
|
||||
// EXPRESSION: args.clone()
|
||||
// RESULT: instance of java.lang.String[0] (id=ID): [Ljava/lang/String;
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
LineBreakpoint created at arrayMethods.kt:5
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
arrayMethods.kt:5
|
||||
Compile bytecode for args.toString().length > 0
|
||||
Compile bytecode for args.hashCode() and 0
|
||||
Compile bytecode for args.clone()
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+33
@@ -0,0 +1,33 @@
|
||||
package arrays
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
//Breakpoint!
|
||||
args.size
|
||||
}
|
||||
|
||||
// EXPRESSION: arrayOf(1, 2).map { it.toString() }
|
||||
// RESULT: instance of java.util.ArrayList(id=ID): Ljava/util/ArrayList;
|
||||
|
||||
// EXPRESSION: arrayOf(1, 2, 101, 102).filter { it > 100 }
|
||||
// RESULT: instance of java.util.ArrayList(id=ID): Ljava/util/ArrayList;
|
||||
|
||||
// EXPRESSION: arrayOf(1, 2).none()
|
||||
// RESULT: 0: Z
|
||||
|
||||
// EXPRESSION: arrayOf(1, 2).count()
|
||||
// RESULT: 2: I
|
||||
|
||||
// EXPRESSION: arrayOf(1, 2).size
|
||||
// RESULT: 2: I
|
||||
|
||||
// EXPRESSION: arrayOf(1, 2).first()
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: arrayOf(1, 2).last()
|
||||
// RESULT: 2: I
|
||||
|
||||
// EXPRESSION: intArrayOf(1, 2).max()
|
||||
// RESULT: instance of java.lang.Integer(id=ID): Ljava/lang/Integer;
|
||||
|
||||
// EXPRESSION: arrayOf(1, 2).max()
|
||||
// RESULT: instance of java.lang.Integer(id=ID): Ljava/lang/Integer;
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
LineBreakpoint created at arrays.kt:5
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
arrays.kt:5
|
||||
Compile bytecode for arrayOf(1, 2).map { it.toString() }
|
||||
Compile bytecode for arrayOf(1, 2, 101, 102).filter { it > 100 }
|
||||
Compile bytecode for arrayOf(1, 2).none()
|
||||
Compile bytecode for arrayOf(1, 2).count()
|
||||
Compile bytecode for arrayOf(1, 2).size
|
||||
Compile bytecode for arrayOf(1, 2).first()
|
||||
Compile bytecode for arrayOf(1, 2).last()
|
||||
Compile bytecode for intArrayOf(1, 2).max()
|
||||
Compile bytecode for arrayOf(1, 2).max()
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
package boxParam
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
val nullableInt: Int? = 1
|
||||
val nullableByte: Byte? = 1
|
||||
|
||||
// EXPRESSION: nullableInt?.plus(1)
|
||||
// RESULT: instance of java.lang.Integer(id=ID): Ljava/lang/Integer;
|
||||
|
||||
// EXPRESSION: nullableByte?.plus(1)
|
||||
// RESULT: instance of java.lang.Integer(id=ID): Ljava/lang/Integer;
|
||||
//Breakpoint!
|
||||
val i = 1
|
||||
}
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
LineBreakpoint created at boxParam.kt:13
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
boxParam.kt:13
|
||||
Compile bytecode for nullableInt?.plus(1)
|
||||
Compile bytecode for nullableByte?.plus(1)
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+12
@@ -0,0 +1,12 @@
|
||||
package boxReturnValue
|
||||
|
||||
inline fun <X: Any> useInline(x: X) {
|
||||
// EXPRESSION: x
|
||||
// RESULT: instance of java.lang.Integer(id=ID): Ljava/lang/Integer;
|
||||
//Breakpoint!
|
||||
val a = 1
|
||||
}
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
useInline(1)
|
||||
}
|
||||
Vendored
+8
@@ -0,0 +1,8 @@
|
||||
LineBreakpoint created at boxReturnValue.kt:7
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
boxReturnValue.kt:7
|
||||
Compile bytecode for x
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
Vendored
+12
@@ -0,0 +1,12 @@
|
||||
package breakpointInInlineFun
|
||||
|
||||
import customLib.inlineFunInLibrary.*
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
inlineFun { }
|
||||
}
|
||||
|
||||
// RESUME: 2
|
||||
|
||||
// ADDITIONAL_BREAKPOINT: inlineFunInLibrary.kt:public inline fun inlineFun
|
||||
// ADDITIONAL_BREAKPOINT: inlineFunInLibrary.kt: Breakpoint 2
|
||||
Vendored
+9
@@ -0,0 +1,9 @@
|
||||
LineBreakpoint created at inlineFunInLibrary.kt:4
|
||||
LineBreakpoint created at inlineFunInLibrary.kt:12
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
inlineFunInLibrary.kt:4
|
||||
inlineFunInLibrary.kt:12
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+15
@@ -0,0 +1,15 @@
|
||||
package callableBug
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
val callable = 1
|
||||
arrayOf(1, 2).map {
|
||||
it + 1
|
||||
//Breakpoint! (lambdaOrdinal = 1)
|
||||
}.forEach { it + 2 }
|
||||
}
|
||||
|
||||
// EXPRESSION: callable
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: it
|
||||
// RESULT: 2: I
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
LineBreakpoint created at callableBug.kt:8 lambdaOrdinal = 1
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
callableBug.kt:8
|
||||
Compile bytecode for callable
|
||||
Compile bytecode for it
|
||||
callableBug.kt:8
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
Vendored
+14
@@ -0,0 +1,14 @@
|
||||
package classFromAnotherPackage
|
||||
|
||||
import forTests.MyJavaClass
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
//Breakpoint!
|
||||
args.size
|
||||
}
|
||||
|
||||
// EXPRESSION: MyJavaClass()
|
||||
// RESULT: instance of forTests.MyJavaClass(id=ID): LforTests/MyJavaClass;
|
||||
|
||||
// EXPRESSION: forTests.MyJavaClass()
|
||||
// RESULT: instance of forTests.MyJavaClass(id=ID): LforTests/MyJavaClass;
|
||||
idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/classFromAnotherPackage.out
Vendored
+9
@@ -0,0 +1,9 @@
|
||||
LineBreakpoint created at classFromAnotherPackage.kt:7
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
classFromAnotherPackage.kt:7
|
||||
Compile bytecode for MyJavaClass()
|
||||
Compile bytecode for forTests.MyJavaClass()
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+22
@@ -0,0 +1,22 @@
|
||||
package classObjectVal
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
MyClass().test()
|
||||
}
|
||||
|
||||
class MyClass {
|
||||
fun test() {
|
||||
//Breakpoint!
|
||||
val a = 1
|
||||
}
|
||||
|
||||
companion object {
|
||||
val coProp = 1
|
||||
}
|
||||
}
|
||||
|
||||
// EXPRESSION: coProp
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: MyClass.coProp
|
||||
// RESULT: 1: I
|
||||
Vendored
+9
@@ -0,0 +1,9 @@
|
||||
LineBreakpoint created at classObjectVal.kt:10
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
classObjectVal.kt:10
|
||||
Compile bytecode for coProp
|
||||
Compile bytecode for MyClass.coProp
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+25
@@ -0,0 +1,25 @@
|
||||
package collections
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
val ar = intArrayOf(1, 2, 100, 200)
|
||||
//Breakpoint!
|
||||
args.size
|
||||
}
|
||||
|
||||
// EXPRESSION: arrayListOf(1, 2).map { it.toString() }
|
||||
// RESULT: instance of java.util.ArrayList(id=ID): Ljava/util/ArrayList;
|
||||
|
||||
// EXPRESSION: arrayListOf(1, 2, 101, 102).filter { it > 100 }
|
||||
// RESULT: instance of java.util.ArrayList(id=ID): Ljava/util/ArrayList;
|
||||
|
||||
// EXPRESSION: arrayListOf(1, 2).max()
|
||||
// RESULT: instance of java.lang.Integer(id=ID): Ljava/lang/Integer;
|
||||
|
||||
// EXPRESSION: arrayListOf(1, 2).count()
|
||||
// RESULT: 2: I
|
||||
|
||||
// EXPRESSION: arrayListOf(1, 2).size
|
||||
// RESULT: 2: I
|
||||
|
||||
// EXPRESSION: arrayListOf(1, 2, 3).drop(1)
|
||||
// RESULT: instance of java.util.ArrayList(id=ID): Ljava/util/ArrayList;
|
||||
Vendored
+5
@@ -0,0 +1,5 @@
|
||||
ar.map { if (it > 50) "big" else "small" }
|
||||
.filter { it == "small" }
|
||||
.size
|
||||
|
||||
// RESULT: 2: I
|
||||
+18
@@ -0,0 +1,18 @@
|
||||
LineBreakpoint created at collections.kt:6
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
collections.kt:6
|
||||
Compile bytecode for arrayListOf(1, 2).map { it.toString() }
|
||||
Compile bytecode for arrayListOf(1, 2, 101, 102).filter { it > 100 }
|
||||
Compile bytecode for arrayListOf(1, 2).max()
|
||||
Compile bytecode for arrayListOf(1, 2).count()
|
||||
Compile bytecode for arrayListOf(1, 2).size
|
||||
Compile bytecode for arrayListOf(1, 2, 3).drop(1)
|
||||
Compile bytecode for ar.map { if (it > 50) "big" else "small" }
|
||||
.filter { it == "small" }
|
||||
.size
|
||||
|
||||
// RESULT: 2: I
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+48
@@ -0,0 +1,48 @@
|
||||
package ceAnonymousObject
|
||||
|
||||
public val publicTopLevelObject: Any = object { fun test() = 1 }
|
||||
private val privateTopLevelObject = object { fun test() = 1 }
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
MyClass().foo()
|
||||
}
|
||||
|
||||
class MyClass {
|
||||
public val publicObject: Any = object { fun test() = 1 }
|
||||
protected val protectedObject: Any = object { fun test() = 1 }
|
||||
private val privateObject = object { fun test() = 1 }
|
||||
|
||||
fun foo() {
|
||||
val localObject = object { fun test() = 1 }
|
||||
//Breakpoint!
|
||||
val a = 1
|
||||
}
|
||||
}
|
||||
|
||||
// EXPRESSION: publicTopLevelObject
|
||||
// RESULT: instance of ceAnonymousObject.CeAnonymousObjectKt$publicTopLevelObject$1(id=ID): LceAnonymousObject/CeAnonymousObjectKt$publicTopLevelObject$1;
|
||||
|
||||
// -EXPRESSION: privateTopLevelObject
|
||||
// -RESULT: 1
|
||||
|
||||
// -EXPRESSION: privateTopLevelObject.test()
|
||||
// -RESULT: 1: I
|
||||
|
||||
// EXPRESSION: publicObject
|
||||
// RESULT: instance of ceAnonymousObject.MyClass$publicObject$1(id=ID): LceAnonymousObject/MyClass$publicObject$1;
|
||||
|
||||
// EXPRESSION: protectedObject
|
||||
// RESULT: instance of ceAnonymousObject.MyClass$protectedObject$1(id=ID): LceAnonymousObject/MyClass$protectedObject$1;
|
||||
|
||||
// -EXPRESSION: privateObject
|
||||
// -RESULT: 1
|
||||
|
||||
// -EXPRESSION: privateObject.test()
|
||||
// -RESULT: 1: I
|
||||
|
||||
// EXPRESSION: localObject
|
||||
// RESULT: instance of ceAnonymousObject.MyClass$foo$localObject$1(id=ID): LceAnonymousObject/MyClass$foo$localObject$1;
|
||||
|
||||
// EXPRESSION: localObject.test()
|
||||
// RESULT: 1: I
|
||||
|
||||
+12
@@ -0,0 +1,12 @@
|
||||
LineBreakpoint created at ceAnonymousObject.kt:18
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
ceAnonymousObject.kt:18
|
||||
Compile bytecode for publicTopLevelObject
|
||||
Compile bytecode for publicObject
|
||||
Compile bytecode for protectedObject
|
||||
Compile bytecode for localObject
|
||||
Compile bytecode for localObject.test()
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
package ceAnonymousObjectCapturedInClosure
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
val localObject = object { fun test() = 1 }
|
||||
var localObjectVar = object { fun test() = 1 }
|
||||
//Breakpoint! (lambdaOrdinal = -1)
|
||||
lambda { localObjectVar.test() }
|
||||
}
|
||||
|
||||
fun lambda(f: () -> Int) = f()
|
||||
|
||||
// EXPRESSION: lambda { localObject.test() }
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: lambda { localObjectVar.test() }
|
||||
// RESULT: 1: I
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
LineBreakpoint created at ceAnonymousObjectCapturedInClosure.kt:7 lambdaOrdinal = -1
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
ceAnonymousObjectCapturedInClosure.kt:7
|
||||
Compile bytecode for lambda { localObject.test() }
|
||||
Compile bytecode for lambda { localObjectVar.test() }
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+20
@@ -0,0 +1,20 @@
|
||||
package ceAnonymousObjectThisAsReceiver
|
||||
|
||||
fun main(args : Array<String>) {
|
||||
val localObject = object {
|
||||
fun test() = 1
|
||||
|
||||
fun foo() {
|
||||
//Breakpoint!
|
||||
val a = 1
|
||||
}
|
||||
}
|
||||
|
||||
localObject.foo()
|
||||
}
|
||||
|
||||
// EXPRESSION: test()
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: this.test()
|
||||
// RESULT: 1: I
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
LineBreakpoint created at ceAnonymousObjectThisAsReceiver.kt:9
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
ceAnonymousObjectThisAsReceiver.kt:9
|
||||
Compile bytecode for test()
|
||||
Compile bytecode for this.test()
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+19
@@ -0,0 +1,19 @@
|
||||
package ceLambda
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
val a = 1
|
||||
//Breakpoint!
|
||||
args.size
|
||||
}
|
||||
|
||||
fun foo(p: () -> Int) = p()
|
||||
|
||||
// EXPRESSION: foo { 1 }
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: foo { a }
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: foo { args.size }
|
||||
// RESULT: 0: I
|
||||
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
LineBreakpoint created at ceLambda.kt:6
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
ceLambda.kt:6
|
||||
Compile bytecode for foo { 1 }
|
||||
Compile bytecode for foo { a }
|
||||
Compile bytecode for foo { args.size }
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
package ceLocalClass
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
val a = 1
|
||||
//Breakpoint!
|
||||
args.size
|
||||
}
|
||||
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
class MyClass {
|
||||
fun test() = 2
|
||||
}
|
||||
|
||||
val a = MyClass()
|
||||
a.test()
|
||||
|
||||
// RESULT: 2: I
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
LineBreakpoint created at ceLocalClass.kt:6
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
ceLocalClass.kt:6
|
||||
Compile bytecode for class MyClass {
|
||||
fun test() = 2
|
||||
}
|
||||
|
||||
val a = MyClass()
|
||||
a.test()
|
||||
|
||||
// RESULT: 2: I
|
||||
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+25
@@ -0,0 +1,25 @@
|
||||
package ceLocalClassMembers
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
A().test()
|
||||
}
|
||||
|
||||
class A {
|
||||
public fun publicFun(): Int = 1
|
||||
public val publicVal: Int = 1
|
||||
|
||||
protected fun protectedFun(): Int = 1
|
||||
protected val protectedVal: Int = 1
|
||||
|
||||
private fun privateFun() = 1
|
||||
private val privateVal = 1
|
||||
|
||||
fun test() {
|
||||
//Breakpoint!
|
||||
val a = 1
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
class MyClass {
|
||||
fun test() = publicFun() + publicVal + protectedFun() + protectedVal + privateFun() + privateFun()
|
||||
}
|
||||
|
||||
val a = MyClass()
|
||||
a.test()
|
||||
|
||||
// RESULT: 6: I
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
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
|
||||
+23
@@ -0,0 +1,23 @@
|
||||
package ceLocalClassWithSuperClass
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
A().test()
|
||||
}
|
||||
|
||||
class A {
|
||||
public fun publicFun(): Int = 1
|
||||
public val publicVal: Int = 1
|
||||
|
||||
protected fun protectedFun(): Int = 1
|
||||
protected val protectedVal: Int = 1
|
||||
|
||||
private fun privateFun() = 1
|
||||
private val privateVal = 1
|
||||
|
||||
fun test() {
|
||||
//Breakpoint!
|
||||
val a = 1
|
||||
}
|
||||
}
|
||||
|
||||
open class MySuperClass
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
class MyClass: MySuperClass() {
|
||||
fun test() = publicFun()
|
||||
}
|
||||
|
||||
val a = MyClass()
|
||||
a.test()
|
||||
|
||||
// RESULT: 1: I
|
||||
+16
@@ -0,0 +1,16 @@
|
||||
LineBreakpoint created at ceLocalClassWithSuperClass.kt:19
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
ceLocalClassWithSuperClass.kt:19
|
||||
Compile bytecode for class MyClass: MySuperClass() {
|
||||
fun test() = publicFun()
|
||||
}
|
||||
|
||||
val a = MyClass()
|
||||
a.test()
|
||||
|
||||
// RESULT: 1: I
|
||||
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+42
@@ -0,0 +1,42 @@
|
||||
package ceMembers
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
A().test()
|
||||
}
|
||||
|
||||
class A {
|
||||
public fun publicFun(): Int = 1
|
||||
public val publicVal: Int = 1
|
||||
|
||||
protected fun protectedFun(): Int = 1
|
||||
protected val protectedVal: Int = 1
|
||||
|
||||
private fun privateFun() = 1
|
||||
private val privateVal = 1
|
||||
|
||||
fun test() {
|
||||
//Breakpoint!
|
||||
val a = 1
|
||||
}
|
||||
}
|
||||
|
||||
fun foo(p: () -> Int) = p()
|
||||
|
||||
// EXPRESSION: foo { publicFun() }
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: foo { publicVal }
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: foo { protectedFun() }
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: foo { protectedVal }
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: foo { privateFun() }
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: foo { privateVal }
|
||||
// RESULT: 1: I
|
||||
|
||||
+13
@@ -0,0 +1,13 @@
|
||||
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
|
||||
+19
@@ -0,0 +1,19 @@
|
||||
package ceObject
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
//Breakpoint!
|
||||
args.size
|
||||
}
|
||||
|
||||
interface T {
|
||||
fun test() = 1
|
||||
}
|
||||
|
||||
// EXPRESSION: (object: T {}).test()
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: (object: T { fun a() = 1 }).a()
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: object: T {}
|
||||
// RESULT: instance of Generated_for_debugger_class$generated_for_debugger_fun$1(id=ID): LGenerated_for_debugger_class$generated_for_debugger_fun$1;
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
LineBreakpoint created at ceObject.kt:5
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
ceObject.kt:5
|
||||
Compile bytecode for (object: T {}).test()
|
||||
Compile bytecode for (object: T { fun a() = 1 }).a()
|
||||
Compile bytecode for object: T {}
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
package ceSeveralLambdas
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
//Breakpoint!
|
||||
args.size
|
||||
}
|
||||
|
||||
fun foo(p: () -> Int) = p()
|
||||
|
||||
// EXPRESSION: foo { 1 } + foo { 1 }
|
||||
// RESULT: 2: I
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
LineBreakpoint created at ceSeveralLambdas.kt:5
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
ceSeveralLambdas.kt:5
|
||||
Compile bytecode for foo { 1 } + foo { 1 }
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+43
@@ -0,0 +1,43 @@
|
||||
package ceSuperAccess
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
A().Inner().test()
|
||||
}
|
||||
|
||||
class A {
|
||||
public fun publicFun(): Int = 1
|
||||
public val publicVal: Int = 1
|
||||
|
||||
protected fun protectedFun(): Int = 1
|
||||
protected val protectedVal: Int = 1
|
||||
|
||||
private fun privateFun() = 1
|
||||
private val privateVal = 1
|
||||
|
||||
inner class Inner {
|
||||
fun test() {
|
||||
//Breakpoint!
|
||||
val a = publicFun()
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
fun foo(p: () -> Int) = p()
|
||||
|
||||
// EXPRESSION: foo { publicFun() }
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: foo { publicVal }
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: foo { protectedFun() }
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: foo { protectedVal }
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: foo { privateFun() }
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: foo { privateVal }
|
||||
// RESULT: 1: I
|
||||
+13
@@ -0,0 +1,13 @@
|
||||
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
|
||||
+32
@@ -0,0 +1,32 @@
|
||||
package anyUpdateInvokeStatic
|
||||
|
||||
import kotlin.sequences.*
|
||||
import kotlin.coroutines.*
|
||||
|
||||
fun builder(c: suspend () -> Unit) {
|
||||
c.startCoroutine(object : Continuation<Unit>{
|
||||
override val context: CoroutineContext
|
||||
get() = EmptyCoroutineContext
|
||||
|
||||
override fun resumeWith(result: Result<Unit>) {
|
||||
result.getOrThrow()
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
object A {
|
||||
@JvmStatic var s: Any? = "aabb"
|
||||
}
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
builder {
|
||||
A.s = strChanger(A.s)
|
||||
//Breakpoint!
|
||||
println(A.s) // (1)
|
||||
}
|
||||
}
|
||||
|
||||
suspend fun strChanger(str: Any?): Any? = (str as String).filter { it !in "a" }
|
||||
|
||||
// EXPRESSION: A.s
|
||||
// RESULT: "bb": Ljava/lang/String;
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
LineBreakpoint created at anyUpdateInvokeStatic.kt:25
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
anyUpdateInvokeStatic.kt:25
|
||||
Compile bytecode for A.s
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
bb
|
||||
+29
@@ -0,0 +1,29 @@
|
||||
package anyUpdateVariable
|
||||
|
||||
import kotlin.sequences.*
|
||||
import kotlin.coroutines.*
|
||||
|
||||
fun builder(c: suspend () -> Unit) {
|
||||
c.startCoroutine(object : Continuation<Unit>{
|
||||
override val context: CoroutineContext
|
||||
get() = EmptyCoroutineContext
|
||||
|
||||
override fun resumeWith(result: Result<Unit>) {
|
||||
result.getOrThrow()
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
builder {
|
||||
var s:Any? = "aabb"
|
||||
s = strChanger(s)
|
||||
//Breakpoint!
|
||||
println(s) // (1)
|
||||
}
|
||||
}
|
||||
|
||||
suspend fun strChanger(str: Any?): Any? = (str as String).filter { it !in "a" }
|
||||
|
||||
// EXPRESSION: s
|
||||
// RESULT: "bb": Ljava/lang/String;
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
LineBreakpoint created at anyUpdateVariable.kt:22
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
anyUpdateVariable.kt:22
|
||||
Compile bytecode for s
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
bb
|
||||
+18
@@ -0,0 +1,18 @@
|
||||
package primitivesCoertion
|
||||
|
||||
import kotlin.sequences.*
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
val a = sequence<Int> {
|
||||
yield(1)
|
||||
val a = awaitSeq()
|
||||
//Breakpoint!
|
||||
println(a) // (1)
|
||||
}
|
||||
println(a.toList())
|
||||
}
|
||||
|
||||
suspend fun SequenceScope<Int>.awaitSeq(): Int = 42
|
||||
|
||||
// EXPRESSION: a
|
||||
// RESULT: 42: I
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
LineBreakpoint created at primitivesCoertion.kt:10
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
primitivesCoertion.kt:10
|
||||
Compile bytecode for a
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
42
|
||||
[1]
|
||||
+32
@@ -0,0 +1,32 @@
|
||||
package stringUpdateInvokeStatic
|
||||
|
||||
import kotlin.sequences.*
|
||||
import kotlin.coroutines.*
|
||||
|
||||
fun builder(c: suspend () -> Unit) {
|
||||
c.startCoroutine(object : Continuation<Unit>{
|
||||
override val context: CoroutineContext
|
||||
get() = EmptyCoroutineContext
|
||||
|
||||
override fun resumeWith(result: Result<Unit>) {
|
||||
result.getOrThrow()
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
object A {
|
||||
@JvmStatic var s: String = "aabb"
|
||||
}
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
builder {
|
||||
A.s = strChanger(A.s)
|
||||
//Breakpoint!
|
||||
println(A.s) // (1)
|
||||
}
|
||||
}
|
||||
|
||||
suspend fun strChanger(str: String): String = str.filter { it !in "a" }
|
||||
|
||||
// EXPRESSION: A.s
|
||||
// RESULT: "bb": Ljava/lang/String;
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
LineBreakpoint created at stringUpdateInvokeStatic.kt:25
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
stringUpdateInvokeStatic.kt:25
|
||||
Compile bytecode for A.s
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
bb
|
||||
+31
@@ -0,0 +1,31 @@
|
||||
package stringUpdateInvokeVirtual
|
||||
|
||||
import kotlin.sequences.*
|
||||
import kotlin.coroutines.*
|
||||
|
||||
fun builder(c: suspend () -> Unit) {
|
||||
c.startCoroutine(object : Continuation<Unit>{
|
||||
override val context: CoroutineContext
|
||||
get() = EmptyCoroutineContext
|
||||
|
||||
override fun resumeWith(result: Result<Unit>) {
|
||||
result.getOrThrow()
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
class A(var s: String)
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
builder {
|
||||
var a = A("aabb")
|
||||
a.s = strChanger(a.s)
|
||||
//Breakpoint!
|
||||
println(a.s) // (1)
|
||||
}
|
||||
}
|
||||
|
||||
suspend fun strChanger(str: String): String = str.filter { it !in "a" }
|
||||
|
||||
// EXPRESSION: a.s
|
||||
// RESULT: "bb": Ljava/lang/String;
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
LineBreakpoint created at stringUpdateInvokeVirtual.kt:24
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
stringUpdateInvokeVirtual.kt:24
|
||||
Compile bytecode for a.s
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
bb
|
||||
+31
@@ -0,0 +1,31 @@
|
||||
package stringUpdatePutField
|
||||
|
||||
import kotlin.sequences.*
|
||||
import kotlin.coroutines.*
|
||||
|
||||
fun builder(c: suspend () -> Unit) {
|
||||
c.startCoroutine(object : Continuation<Unit>{
|
||||
override val context: CoroutineContext
|
||||
get() = EmptyCoroutineContext
|
||||
|
||||
override fun resumeWith(result: Result<Unit>) {
|
||||
result.getOrThrow()
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
class A(@JvmField var s: String)
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
builder {
|
||||
var a = A("aabb")
|
||||
a.s = strChanger(a.s)
|
||||
//Breakpoint!
|
||||
println(a.s) // (1)
|
||||
}
|
||||
}
|
||||
|
||||
suspend fun strChanger(str: String): String = str.filter { it !in "a" }
|
||||
|
||||
// EXPRESSION: a.s
|
||||
// RESULT: "bb": Ljava/lang/String;
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
LineBreakpoint created at stringUpdatePutField.kt:24
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
stringUpdatePutField.kt:24
|
||||
Compile bytecode for a.s
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
bb
|
||||
+29
@@ -0,0 +1,29 @@
|
||||
package stringUpdateVariable
|
||||
|
||||
import kotlin.sequences.*
|
||||
import kotlin.coroutines.*
|
||||
|
||||
fun builder(c: suspend () -> Unit) {
|
||||
c.startCoroutine(object : Continuation<Unit>{
|
||||
override val context: CoroutineContext
|
||||
get() = EmptyCoroutineContext
|
||||
|
||||
override fun resumeWith(result: Result<Unit>) {
|
||||
result.getOrThrow()
|
||||
}
|
||||
})
|
||||
}
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
builder {
|
||||
var s = "aabb"
|
||||
s = strChanger(s)
|
||||
//Breakpoint!
|
||||
println(s) // (1)
|
||||
}
|
||||
}
|
||||
|
||||
suspend fun strChanger(str: String): String = str.filter { it !in "a" }
|
||||
|
||||
// EXPRESSION: s
|
||||
// RESULT: "bb": Ljava/lang/String;
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
LineBreakpoint created at stringUpdateVariable.kt:22
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
stringUpdateVariable.kt:22
|
||||
Compile bytecode for s
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
bb
|
||||
+12
@@ -0,0 +1,12 @@
|
||||
package createExpressionCastToBuiltIn
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
val primitiveArray = intArrayOf(1)
|
||||
val stringArray = arrayOf("a")
|
||||
//Breakpoint!
|
||||
val a = 1
|
||||
}
|
||||
|
||||
// PRINT_FRAME
|
||||
// SKIP: value, hash, hash32, offset, count
|
||||
// DESCRIPTOR_VIEW_OPTIONS: NAME_EXPRESSION_RESULT
|
||||
+18
@@ -0,0 +1,18 @@
|
||||
LineBreakpoint created at createExpressionCastToBuiltIn.kt:7
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
createExpressionCastToBuiltIn.kt:7
|
||||
Compile bytecode for args
|
||||
Compile bytecode for primitiveArray
|
||||
Compile bytecode for primitiveArray[0]
|
||||
Compile bytecode for stringArray
|
||||
Compile bytecode for stringArray[0]
|
||||
frame = main
|
||||
local = args (expression = args)
|
||||
local = primitiveArray (expression = primitiveArray)
|
||||
element = 0 (expression = primitiveArray[0])
|
||||
local = stringArray (expression = stringArray)
|
||||
element = 0 (expression = stringArray[0])
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+19
@@ -0,0 +1,19 @@
|
||||
package createExpressionSimple
|
||||
|
||||
class MyClass: Base() {
|
||||
val i = 1
|
||||
}
|
||||
|
||||
open class Base {
|
||||
val baseI = 2
|
||||
}
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
val myClass: Base = MyClass()
|
||||
val myBase = Base()
|
||||
//Breakpoint!
|
||||
val a = 1
|
||||
}
|
||||
|
||||
// PRINT_FRAME
|
||||
// DESCRIPTOR_VIEW_OPTIONS: NAME_EXPRESSION
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
LineBreakpoint created at createExpressionSimple.kt:15
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
createExpressionSimple.kt:15
|
||||
frame = main
|
||||
local = args (expression = args)
|
||||
local = myClass (expression = myClass)
|
||||
field = i (expression = (myClass as MyClass).i)
|
||||
field = baseI (expression = (myClass as MyClass).baseI)
|
||||
local = myBase (expression = myBase)
|
||||
field = baseI (expression = myBase.baseI)
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+15
@@ -0,0 +1,15 @@
|
||||
package createExpressionWithArray
|
||||
|
||||
import forTests.MyJavaClass
|
||||
// do not remove this import, it checks that we do not insert ambiguous imports during EE
|
||||
import forTests.MyJavaClass.InnerClass
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
val baseArray = arrayOf(MyJavaClass().getBaseClassValue())
|
||||
val innerArray = arrayOf(MyJavaClass().getInnerClassValue())
|
||||
//Breakpoint!
|
||||
val a = 1
|
||||
}
|
||||
|
||||
// PRINT_FRAME
|
||||
// DESCRIPTOR_VIEW_OPTIONS: NAME_EXPRESSION_RESULT
|
||||
+24
@@ -0,0 +1,24 @@
|
||||
LineBreakpoint created at createExpressionWithArray.kt:11
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
createExpressionWithArray.kt:11
|
||||
Compile bytecode for args
|
||||
Compile bytecode for baseArray
|
||||
Compile bytecode for baseArray[0]
|
||||
Compile bytecode for baseArray[0].i2
|
||||
Compile bytecode for innerArray
|
||||
Compile bytecode for innerArray[0]
|
||||
Compile bytecode for (innerArray[0] as InnerClass).i
|
||||
Compile bytecode for (innerArray[0] as InnerClass).i2
|
||||
frame = main
|
||||
local = args (expression = args)
|
||||
local = baseArray (expression = baseArray)
|
||||
element = 0 (expression = baseArray[0])
|
||||
field = i2 (expression = baseArray[0].i2)
|
||||
local = innerArray (expression = innerArray)
|
||||
element = 0 (expression = innerArray[0])
|
||||
field = i (expression = (innerArray[0] as InnerClass).i)
|
||||
field = i2 (expression = (innerArray[0] as InnerClass).i2)
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+18
@@ -0,0 +1,18 @@
|
||||
package dataClassCopy
|
||||
|
||||
fun main() {
|
||||
val a = Foo("foo")
|
||||
//Breakpoint!
|
||||
a.copy("bar")
|
||||
}
|
||||
|
||||
data class Foo(val a: String)
|
||||
|
||||
// STEP_INTO: 1
|
||||
// STEP_OUT: 1
|
||||
|
||||
// EXPRESSION: Foo("baz")
|
||||
// RESULT: instance of dataClassCopy.Foo(id=ID): LdataClassCopy/Foo;
|
||||
|
||||
// EXPRESSION: a
|
||||
// RESULT: Unresolved reference: a
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
LineBreakpoint created at dataClassCopy.kt:6
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
dataClassCopy.kt:6
|
||||
dataClassCopy.kt:9
|
||||
dataClassCopy.kt:-1
|
||||
Compile bytecode for Foo("baz")
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
Vendored
+19
@@ -0,0 +1,19 @@
|
||||
package defaultParameterValues
|
||||
|
||||
fun main() {
|
||||
foo(3)
|
||||
}
|
||||
|
||||
fun foo(
|
||||
b: Int,
|
||||
//Breakpoint!
|
||||
a: Int = 5
|
||||
) {
|
||||
val c = 5
|
||||
}
|
||||
|
||||
// EXPRESSION: a
|
||||
// RESULT: Parameter evaluation is not supported for '$default' methods
|
||||
|
||||
// EXPRESSION: b
|
||||
// RESULT: Parameter evaluation is not supported for '$default' methods
|
||||
Vendored
+9
@@ -0,0 +1,9 @@
|
||||
LineBreakpoint created at defaultParameterValues.kt:10
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
defaultParameterValues.kt:10
|
||||
Compile bytecode for a
|
||||
Compile bytecode for b
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
Vendored
+20
@@ -0,0 +1,20 @@
|
||||
package defaultParameterValues2
|
||||
|
||||
fun main() {
|
||||
Foo().foo()
|
||||
}
|
||||
|
||||
interface IFoo {
|
||||
//Breakpoint!
|
||||
fun foo(a: Int = 1)
|
||||
}
|
||||
|
||||
class Foo : IFoo {
|
||||
override fun foo(a: Int) {}
|
||||
}
|
||||
|
||||
// EXPRESSION: Foo()
|
||||
// RESULT: instance of defaultParameterValues2.Foo(id=ID): LdefaultParameterValues2/Foo;
|
||||
|
||||
// EXPRESSION: a
|
||||
// RESULT: Parameter evaluation is not supported for '$default' methods
|
||||
idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/defaultParameterValues2.out
Vendored
+9
@@ -0,0 +1,9 @@
|
||||
LineBreakpoint created at defaultParameterValues2.kt:9
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
defaultParameterValues2.kt:9
|
||||
Compile bytecode for Foo()
|
||||
Compile bytecode for a
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+13
@@ -0,0 +1,13 @@
|
||||
package delegatedPropertyInOtherFile
|
||||
|
||||
import delegatedPropertyInOtherFileOther.*
|
||||
|
||||
fun main(a: Array<String>) {
|
||||
val t = WithDelegate()
|
||||
|
||||
//Breakpoint!
|
||||
t.a
|
||||
}
|
||||
|
||||
// EXPRESSION: t.a
|
||||
// RESULT: 12: I
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
LineBreakpoint created at delegatedPropertyInOtherFile.kt:9
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
delegatedPropertyInOtherFile.kt:9
|
||||
Compile bytecode for t.a
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
Vendored
+10
@@ -0,0 +1,10 @@
|
||||
package delegatedVariables
|
||||
|
||||
fun main() {
|
||||
val a by lazy { "foo" }
|
||||
//Breakpoint!
|
||||
val b = a
|
||||
}
|
||||
|
||||
// EXPRESSION: a
|
||||
// RESULT: "foo": Ljava/lang/String;
|
||||
Vendored
+8
@@ -0,0 +1,8 @@
|
||||
LineBreakpoint created at delegatedVariables.kt:6
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
delegatedVariables.kt:6
|
||||
Compile bytecode for a
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
Vendored
+56
@@ -0,0 +1,56 @@
|
||||
package dependentOnFile
|
||||
|
||||
import kotlin.reflect.KProperty
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
//Breakpoint!
|
||||
args.size
|
||||
}
|
||||
|
||||
class TestClass {
|
||||
fun testFun() = 1
|
||||
|
||||
companion object {
|
||||
val p = 1
|
||||
}
|
||||
}
|
||||
|
||||
fun testFun() = 1
|
||||
fun Int.testExtFun() = 1
|
||||
|
||||
object TestObject {
|
||||
val p = 1
|
||||
}
|
||||
|
||||
val testVal = 1
|
||||
val Int.testExtVal: Int get() = 1
|
||||
val testDelVal by Delegate()
|
||||
|
||||
class Delegate {
|
||||
operator fun getValue(a: Any?, b: KProperty<*>) = 1
|
||||
}
|
||||
|
||||
// EXPRESSION: TestClass().testFun()
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: testFun()
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: TestObject.p
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: TestClass.p
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: 1.testExtFun()
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: testVal
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: 1.testExtVal
|
||||
// RESULT: 1: I
|
||||
|
||||
// EXPRESSION: testDelVal
|
||||
// RESULT: 1: I
|
||||
|
||||
Vendored
+15
@@ -0,0 +1,15 @@
|
||||
LineBreakpoint created at dependentOnFile.kt:7
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
dependentOnFile.kt:7
|
||||
Compile bytecode for TestClass().testFun()
|
||||
Compile bytecode for testFun()
|
||||
Compile bytecode for TestObject.p
|
||||
Compile bytecode for TestClass.p
|
||||
Compile bytecode for 1.testExtFun()
|
||||
Compile bytecode for testVal
|
||||
Compile bytecode for 1.testExtVal
|
||||
Compile bytecode for testDelVal
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+11
@@ -0,0 +1,11 @@
|
||||
package doubles
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
val d1 = 1.0
|
||||
val d2 = 3.0
|
||||
//Breakpoint!
|
||||
args.size
|
||||
}
|
||||
|
||||
// EXPRESSION: d1 + d2
|
||||
// RESULT: 4.0: D
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
LineBreakpoint created at doubles.kt:7
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
doubles.kt:7
|
||||
Compile bytecode for d1 + d2
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+13
@@ -0,0 +1,13 @@
|
||||
package enums
|
||||
|
||||
import enums.MyEnum.A
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
//Breakpoint!
|
||||
args.size
|
||||
}
|
||||
|
||||
enum class MyEnum { A }
|
||||
|
||||
// EXPRESSION: A == MyEnum.A
|
||||
// RESULT: 1: Z
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
LineBreakpoint created at enums.kt:7
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
enums.kt:7
|
||||
Compile bytecode for A == MyEnum.A
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+31
@@ -0,0 +1,31 @@
|
||||
package errors
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
MyClass().baseFun()
|
||||
}
|
||||
|
||||
class MyClass: Base() {
|
||||
override fun baseFun() {
|
||||
var prop = 1
|
||||
var prop2 = 2
|
||||
|
||||
//Breakpoint!
|
||||
prop.minus(prop2)
|
||||
}
|
||||
}
|
||||
|
||||
open class Base {
|
||||
open fun baseFun() {}
|
||||
}
|
||||
|
||||
// EXPRESSION: a
|
||||
// RESULT: Unresolved reference: a
|
||||
|
||||
// EXPRESSION: a + 1
|
||||
// RESULT: Unresolved reference: a
|
||||
|
||||
// EXPRESSION: prop.
|
||||
// RESULT: Expecting an element; looking at ERROR_ELEMENT '(1,6) in /fragment.kt
|
||||
|
||||
// EXPRESSION: super.baseFun()
|
||||
// RESULT: VOID_VALUE
|
||||
Vendored
+5
@@ -0,0 +1,5 @@
|
||||
prop += 1
|
||||
prop2 +=2
|
||||
prop + prop2
|
||||
|
||||
// RESULT: 6: I
|
||||
+13
@@ -0,0 +1,13 @@
|
||||
LineBreakpoint created at errors.kt:13
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
errors.kt:13
|
||||
Compile bytecode for super.baseFun()
|
||||
Compile bytecode for prop += 1
|
||||
prop2 +=2
|
||||
prop + prop2
|
||||
|
||||
// RESULT: 6: I
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
package escapedNames
|
||||
|
||||
fun main() {
|
||||
val `one + one` = 1
|
||||
//Breakpoint!
|
||||
val a = 5
|
||||
}
|
||||
|
||||
// EXPRESSION: `one + one` + 100
|
||||
// RESULT: 101: I
|
||||
+8
@@ -0,0 +1,8 @@
|
||||
LineBreakpoint created at escapedNames.kt:6
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
escapedNames.kt:6
|
||||
Compile bytecode for `one + one` + 100
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
Vendored
+15
@@ -0,0 +1,15 @@
|
||||
package experimentalApi
|
||||
|
||||
@Experimental(Experimental.Level.ERROR)
|
||||
annotation class UnstableApi
|
||||
|
||||
@UnstableApi
|
||||
fun foo() = 5
|
||||
|
||||
fun main() {
|
||||
//Breakpoint!
|
||||
val a = 5
|
||||
}
|
||||
|
||||
// EXPRESSION: foo()
|
||||
// RESULT: 5: I
|
||||
Vendored
+8
@@ -0,0 +1,8 @@
|
||||
LineBreakpoint created at experimentalApi.kt:11
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
experimentalApi.kt:11
|
||||
Compile bytecode for foo()
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+18
@@ -0,0 +1,18 @@
|
||||
package evBreakpointOnPropertyDeclaration
|
||||
|
||||
class A {
|
||||
var prop = 1
|
||||
}
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
val a1 = A()
|
||||
val a2 = A()
|
||||
val a3 = A()
|
||||
|
||||
val p1 = a1.prop
|
||||
//Breakpoint!
|
||||
val p2 = a2.prop
|
||||
val p3 = a3.prop
|
||||
}
|
||||
|
||||
// PRINT_FRAME
|
||||
+17
@@ -0,0 +1,17 @@
|
||||
LineBreakpoint created at evBreakpointOnPropertyDeclaration.kt:14
|
||||
Run Java
|
||||
Connected to the target VM
|
||||
evBreakpointOnPropertyDeclaration.kt:14
|
||||
Compile bytecode for a2.prop
|
||||
frame = main:14, EvBreakpointOnPropertyDeclarationKt {evBreakpointOnPropertyDeclaration}
|
||||
local = args: java.lang.String[] = {java.lang.String[0]@uniqueID} (sp = evBreakpointOnPropertyDeclaration.kt, 7)
|
||||
local = a1: evBreakpointOnPropertyDeclaration.A = {evBreakpointOnPropertyDeclaration.A@uniqueID} (sp = evBreakpointOnPropertyDeclaration.kt, 8)
|
||||
field = prop: int = 1 (sp = evBreakpointOnPropertyDeclaration.kt, 4)
|
||||
local = a2: evBreakpointOnPropertyDeclaration.A = {evBreakpointOnPropertyDeclaration.A@uniqueID} (sp = evBreakpointOnPropertyDeclaration.kt, 9)
|
||||
field = prop: int = 1 (sp = evBreakpointOnPropertyDeclaration.kt, 4)
|
||||
local = a3: evBreakpointOnPropertyDeclaration.A = {evBreakpointOnPropertyDeclaration.A@uniqueID} (sp = evBreakpointOnPropertyDeclaration.kt, 10)
|
||||
field = prop: int = 1 (sp = evBreakpointOnPropertyDeclaration.kt, 4)
|
||||
local = p1: int = 1 (sp = evBreakpointOnPropertyDeclaration.kt, 12)
|
||||
Disconnected from the target VM
|
||||
|
||||
Process finished with exit code 0
|
||||
+17
@@ -0,0 +1,17 @@
|
||||
package evDelegatedProperty
|
||||
|
||||
import kotlin.properties.Delegates
|
||||
|
||||
class A {
|
||||
var prop: Int by Delegates.notNull()
|
||||
}
|
||||
|
||||
fun main(args: Array<String>) {
|
||||
val a = A()
|
||||
a.prop = 1
|
||||
//Breakpoint!
|
||||
val b = a.prop
|
||||
}
|
||||
|
||||
// PRINT_FRAME
|
||||
// RENDER_DELEGATED_PROPERTIES
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user