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
@@ -21,7 +21,11 @@ enum class TargetBackend(
WASM(true),
ANDROID(false, JVM),
ANDROID_IR(true, JVM_IR),
NATIVE(true);
NATIVE(true),
JVM_WITH_OLD_EVALUATOR(false),
JVM_IR_WITH_OLD_EVALUATOR(true),
JVM_WITH_IR_EVALUATOR(false),
JVM_IR_WITH_IR_EVALUATOR(true);
val compatibleWith get() = compatibleWithTargetBackend ?: ANY
}
@@ -241,13 +241,23 @@ fun main(args: Array<String>) {
}
testClass<AbstractKotlinEvaluateExpressionTest> {
model("evaluation/singleBreakpoint", testMethod = "doSingleBreakpointTest")
model("evaluation/multipleBreakpoints", testMethod = "doMultipleBreakpointsTest")
model("evaluation/singleBreakpoint", testMethod = "doSingleBreakpointTest", targetBackend = TargetBackend.JVM_WITH_OLD_EVALUATOR)
model("evaluation/multipleBreakpoints", testMethod = "doMultipleBreakpointsTest", targetBackend = TargetBackend.JVM_WITH_OLD_EVALUATOR)
}
testClass<AbstractIrKotlinEvaluateExpressionTest> {
model("evaluation/singleBreakpoint", testMethod = "doSingleBreakpointTest", targetBackend = TargetBackend.JVM_IR)
model("evaluation/multipleBreakpoints", testMethod = "doMultipleBreakpointsTest", targetBackend = TargetBackend.JVM_IR)
model("evaluation/singleBreakpoint", testMethod = "doSingleBreakpointTest", targetBackend = TargetBackend.JVM_IR_WITH_OLD_EVALUATOR)
model("evaluation/multipleBreakpoints", testMethod = "doMultipleBreakpointsTest", targetBackend = TargetBackend.JVM_IR_WITH_OLD_EVALUATOR)
}
testClass<AbstractKotlinEvaluateExpressionWithIRFragmentCompilerTest> {
model("evaluation/singleBreakpoint", testMethod = "doSingleBreakpointTest", targetBackend = TargetBackend.JVM_WITH_IR_EVALUATOR)
model("evaluation/multipleBreakpoints", testMethod = "doMultipleBreakpointsTest", targetBackend = TargetBackend.JVM_WITH_IR_EVALUATOR)
}
testClass<AbstractIrKotlinEvaluateExpressionWithIRFragmentCompilerTest> {
model("evaluation/singleBreakpoint", testMethod = "doSingleBreakpointTest", targetBackend = TargetBackend.JVM_IR_WITH_IR_EVALUATOR)
model("evaluation/multipleBreakpoints", testMethod = "doMultipleBreakpointsTest", targetBackend = TargetBackend.JVM_IR_WITH_IR_EVALUATOR)
}
testClass<AbstractSelectExpressionForDebuggerTest> {
@@ -5,6 +5,7 @@
package org.jetbrains.kotlin.idea.debugger.evaluate.compilation
import com.intellij.openapi.util.Key
import org.jetbrains.kotlin.backend.common.output.OutputFile
import org.jetbrains.kotlin.codegen.*
import org.jetbrains.kotlin.codegen.CodeFragmentCodegen.Companion.getSharedTypeIfApplicable
@@ -46,6 +47,17 @@ import org.jetbrains.kotlin.types.SimpleType
import org.jetbrains.kotlin.utils.Printer
class CodeFragmentCompiler(private val executionContext: ExecutionContext, private val status: EvaluationStatus) {
companion object {
enum class FragmentCompilerBackend {
JVM,
JVM_IR
}
val KOTLIN_EVALUATOR_FRAGMENT_COMPILER_BACKEND: Key<FragmentCompilerBackend> =
Key.create("KOTLIN_EVALUATOR_FRAGMENT_COMPILER_BACKEND")
}
data class CompilationResult(
val classes: List<ClassToLoad>,
val parameterInfo: CodeFragmentParameterInfo,
@@ -84,7 +96,13 @@ class CodeFragmentCompiler(private val executionContext: ExecutionContext, priva
val generationState = GenerationState.Builder(
project, ClassBuilderFactories.BINARIES, moduleDescriptorWrapper,
bindingContext, filesToCompile, compilerConfiguration
).generateDeclaredClassFilter(GeneratedClassFilterForCodeFragment(codeFragment)).build()
).apply {
val fragmentCompilerBackend = executionContext.debugProcess.getUserData(KOTLIN_EVALUATOR_FRAGMENT_COMPILER_BACKEND)
if (fragmentCompilerBackend == FragmentCompilerBackend.JVM_IR) {
codegenFactory(TODO("Not implemented yet: EE-IR Fragment Compiler"))
}
generateDeclaredClassFilter(GeneratedClassFilterForCodeFragment(codeFragment))
}.build()
val parameterInfo = CodeFragmentParameterAnalyzer(executionContext, codeFragment, bindingContext, status).analyze()
val (classDescriptor, methodDescriptor) = createDescriptorsForCodeFragment(
@@ -0,0 +1,14 @@
/*
* Copyright 2010-2021 JetBrains s.r.o. and Kotlin Programming Language contributors.
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
*/
package org.jetbrains.kotlin.idea.debugger.test
import org.jetbrains.kotlin.idea.debugger.evaluate.compilation.CodeFragmentCompiler
abstract class AbstractIrKotlinEvaluateExpressionWithIRFragmentCompilerTest : AbstractKotlinEvaluateExpressionTest() {
override fun useIrBackend(): Boolean = true
override fun fragmentCompilerBackend() =
CodeFragmentCompiler.Companion.FragmentCompilerBackend.JVM_IR
}
@@ -13,7 +13,9 @@ import com.intellij.debugger.engine.evaluation.TextWithImportsImpl
import com.intellij.debugger.engine.evaluation.expression.EvaluatorBuilderImpl
import com.intellij.debugger.impl.DebuggerContextImpl
import com.intellij.debugger.impl.DebuggerContextImpl.createDebuggerContext
import com.intellij.debugger.impl.OutputChecker
import com.intellij.debugger.ui.impl.watch.NodeDescriptorImpl
import com.intellij.openapi.application.ex.PathManagerEx.getTestDataPath
import com.intellij.openapi.util.io.FileUtil
import com.intellij.ui.treeStructure.Tree
import com.intellij.xdebugger.impl.ui.tree.ValueMarkup
@@ -23,6 +25,7 @@ import org.jetbrains.eval4j.Value
import org.jetbrains.eval4j.jdi.asValue
import org.jetbrains.kotlin.idea.KotlinFileType
import org.jetbrains.kotlin.idea.debugger.evaluate.KotlinCodeFragmentFactory
import org.jetbrains.kotlin.idea.debugger.evaluate.compilation.CodeFragmentCompiler
import org.jetbrains.kotlin.idea.debugger.test.preference.DebuggerPreferences
import org.jetbrains.kotlin.idea.debugger.test.util.FramePrinter
import org.jetbrains.kotlin.idea.debugger.test.util.FramePrinterDelegate
@@ -33,7 +36,6 @@ import org.jetbrains.kotlin.test.InTextDirectivesUtils
import org.jetbrains.kotlin.test.InTextDirectivesUtils.findLinesWithPrefixesRemoved
import org.jetbrains.kotlin.test.InTextDirectivesUtils.findStringWithPrefixes
import org.jetbrains.kotlin.test.KotlinBaseTest
import org.jetbrains.kotlin.test.TargetBackend
import java.io.File
import java.util.concurrent.ConcurrentHashMap
import javax.swing.tree.TreeNode
@@ -109,8 +111,6 @@ abstract class AbstractKotlinEvaluateExpressionTest : KotlinDescriptorTestCaseWi
doOnBreakpoint {
createDebugLabels(data.debugLabels)
val exceptions = linkedMapOf<String, Throwable>()
for ((expression, expected, kind) in data.fragments) {
mayThrow(expression) {
evaluate(this, expression, kind, expected)
@@ -161,6 +161,11 @@ abstract class AbstractKotlinEvaluateExpressionTest : KotlinDescriptorTestCaseWi
val contextElement = ContextUtil.getContextElement(debuggerContext)!!
evaluationContext.debugProcess.putUserData(
CodeFragmentCompiler.KOTLIN_EVALUATOR_FRAGMENT_COMPILER_BACKEND,
fragmentCompilerBackend()
)
assert(KotlinCodeFragmentFactory().isContextAccepted(contextElement)) {
val text = runReadAction { contextElement.text }
"KotlinCodeFragmentFactory should be accepted for context element otherwise default evaluator will be called. " +
@@ -223,12 +228,20 @@ abstract class AbstractKotlinEvaluateExpressionTest : KotlinDescriptorTestCaseWi
}
}
override fun initOutputChecker(): OutputChecker {
return KotlinOutputChecker(
getTestDataPath(),
testAppPath,
appOutputPath,
targetBackend(),
getExpectedOutputFile()
)
}
override fun throwExceptionsIfAny() {
if (exceptions.isNotEmpty()) {
val isIgnored = InTextDirectivesUtils.isIgnoredTarget(
if (useIrBackend()) TargetBackend.JVM_IR else TargetBackend.JVM,
getExpectedOutputFile()
)
val outputFile = getExpectedOutputFile()
val isIgnored = outputFile.exists() && InTextDirectivesUtils.isIgnoredTarget(targetBackend(), outputFile)
if (!isIgnored) {
for (exc in exceptions.values) {
@@ -0,0 +1,14 @@
/*
* Copyright 2010-2021 JetBrains s.r.o. and Kotlin Programming Language contributors.
* Use of this source code is governed by the Apache 2.0 license that can be found in the license/LICENSE.txt file.
*/
package org.jetbrains.kotlin.idea.debugger.test
import org.jetbrains.kotlin.idea.debugger.evaluate.compilation.CodeFragmentCompiler
abstract class AbstractKotlinEvaluateExpressionWithIRFragmentCompilerTest : AbstractKotlinEvaluateExpressionTest() {
override fun useIrBackend(): Boolean = false
override fun fragmentCompilerBackend() =
CodeFragmentCompiler.Companion.FragmentCompilerBackend.JVM_IR
}
@@ -25,7 +25,7 @@ public class IrKotlinEvaluateExpressionTestGenerated extends AbstractIrKotlinEva
@RunWith(JUnit3RunnerWithInners.class)
public static class SingleBreakpoint extends AbstractIrKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_IR, testDataFilePath);
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, testDataFilePath);
}
@TestMetadata("abstractFunCall.kt")
@@ -39,7 +39,7 @@ public class IrKotlinEvaluateExpressionTestGenerated extends AbstractIrKotlinEva
}
public void testAllFilesPresentInSingleBreakpoint() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("annotationValue.kt")
@@ -97,6 +97,11 @@ public class IrKotlinEvaluateExpressionTestGenerated extends AbstractIrKotlinEva
runTest("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/collections.kt");
}
@TestMetadata("color.kt")
public void testColor() throws Exception {
runTest("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/color.kt");
}
@TestMetadata("dataClassCopy.kt")
public void testDataClassCopy() throws Exception {
runTest("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/dataClassCopy.kt");
@@ -527,11 +532,11 @@ public class IrKotlinEvaluateExpressionTestGenerated extends AbstractIrKotlinEva
@RunWith(JUnit3RunnerWithInners.class)
public static class CompilingEvaluator extends AbstractIrKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_IR, testDataFilePath);
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInCompilingEvaluator() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/compilingEvaluator"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/compilingEvaluator"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("ceAnonymousObject.kt")
@@ -595,11 +600,11 @@ public class IrKotlinEvaluateExpressionTestGenerated extends AbstractIrKotlinEva
@RunWith(JUnit3RunnerWithInners.class)
public static class Coroutines extends AbstractIrKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_IR, testDataFilePath);
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInCoroutines() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/coroutines"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/coroutines"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("anyUpdateInvokeStatic.kt")
@@ -648,11 +653,11 @@ public class IrKotlinEvaluateExpressionTestGenerated extends AbstractIrKotlinEva
@RunWith(JUnit3RunnerWithInners.class)
public static class CreateExpression extends AbstractIrKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_IR, testDataFilePath);
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInCreateExpression() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/createExpression"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/createExpression"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("createExpressionCastToBuiltIn.kt")
@@ -676,11 +681,11 @@ public class IrKotlinEvaluateExpressionTestGenerated extends AbstractIrKotlinEva
@RunWith(JUnit3RunnerWithInners.class)
public static class ExtraVariables extends AbstractIrKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_IR, testDataFilePath);
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInExtraVariables() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/extraVariables"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/extraVariables"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("evBreakpointOnPropertyDeclaration.kt")
@@ -744,11 +749,11 @@ public class IrKotlinEvaluateExpressionTestGenerated extends AbstractIrKotlinEva
@RunWith(JUnit3RunnerWithInners.class)
public static class Frame extends AbstractIrKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_IR, testDataFilePath);
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInFrame() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/frame"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/frame"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("capturedValues1.kt")
@@ -997,11 +1002,11 @@ public class IrKotlinEvaluateExpressionTestGenerated extends AbstractIrKotlinEva
@RunWith(JUnit3RunnerWithInners.class)
public static class JavaContext extends AbstractIrKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_IR, testDataFilePath);
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInJavaContext() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/javaContext"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/javaContext"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("jcBlock.kt")
@@ -1040,11 +1045,11 @@ public class IrKotlinEvaluateExpressionTestGenerated extends AbstractIrKotlinEva
@RunWith(JUnit3RunnerWithInners.class)
public static class Labels extends AbstractIrKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_IR, testDataFilePath);
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInLabels() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/labels"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/labels"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("lCallOnLabeledObj.kt")
@@ -1078,11 +1083,11 @@ public class IrKotlinEvaluateExpressionTestGenerated extends AbstractIrKotlinEva
@RunWith(JUnit3RunnerWithInners.class)
public static class Lambdas extends AbstractIrKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_IR, testDataFilePath);
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInLambdas() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/lambdas"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/lambdas"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("destructuringParam.kt")
@@ -1141,11 +1146,11 @@ public class IrKotlinEvaluateExpressionTestGenerated extends AbstractIrKotlinEva
@RunWith(JUnit3RunnerWithInners.class)
public static class Renderer extends AbstractIrKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_IR, testDataFilePath);
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInRenderer() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/renderer"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/renderer"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("toStringRenderer.kt")
@@ -1160,11 +1165,11 @@ public class IrKotlinEvaluateExpressionTestGenerated extends AbstractIrKotlinEva
@RunWith(JUnit3RunnerWithInners.class)
public static class MultipleBreakpoints extends AbstractIrKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doMultipleBreakpointsTest, TargetBackend.JVM_IR, testDataFilePath);
KotlinTestUtils.runTest(this::doMultipleBreakpointsTest, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInMultipleBreakpoints() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/multipleBreakpoints"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/multipleBreakpoints"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("clearCache.kt")
@@ -1297,11 +1302,11 @@ public class IrKotlinEvaluateExpressionTestGenerated extends AbstractIrKotlinEva
@RunWith(JUnit3RunnerWithInners.class)
public static class Library extends AbstractIrKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doMultipleBreakpointsTest, TargetBackend.JVM_IR, testDataFilePath);
KotlinTestUtils.runTest(this::doMultipleBreakpointsTest, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInLibrary() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/multipleBreakpoints/library"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/multipleBreakpoints/library"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_IR_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("customLibClassName.kt")
@@ -24,6 +24,7 @@ import com.intellij.xdebugger.XDebugSession
import org.jetbrains.kotlin.codegen.forTestCompile.ForTestCompileRuntime
import org.jetbrains.kotlin.config.JvmTarget
import org.jetbrains.kotlin.idea.debugger.evaluate.KotlinDebuggerCaches
import org.jetbrains.kotlin.idea.debugger.evaluate.compilation.CodeFragmentCompiler
import org.jetbrains.kotlin.idea.debugger.test.preference.*
import org.jetbrains.kotlin.idea.debugger.test.util.BreakpointCreator
import org.jetbrains.kotlin.idea.debugger.test.util.KotlinOutputChecker
@@ -34,6 +35,7 @@ import org.jetbrains.kotlin.test.*
import org.jetbrains.kotlin.test.KotlinBaseTest.TestFile
import org.jetbrains.kotlin.test.testFramework.runWriteAction
import org.jetbrains.kotlin.test.util.KtTestUtil
import org.jetbrains.kotlin.test.TargetBackend
import org.junit.ComparisonFailure
import java.io.File
@@ -150,7 +152,13 @@ abstract class KotlinDescriptorTestCase : DescriptorTestCase() {
abstract fun doMultiFileTest(files: TestFiles, preferences: DebuggerPreferences)
override fun initOutputChecker(): OutputChecker {
return KotlinOutputChecker(getTestDirectoryPath(), testAppPath, appOutputPath, useIrBackend(), getExpectedOutputFile())
return KotlinOutputChecker(
getTestDirectoryPath(),
testAppPath,
appOutputPath,
targetBackend(),
getExpectedOutputFile()
)
}
override fun setUpModule() {
@@ -221,6 +229,16 @@ abstract class KotlinDescriptorTestCase : DescriptorTestCase() {
}
}
open fun fragmentCompilerBackend() = CodeFragmentCompiler.Companion.FragmentCompilerBackend.JVM
protected fun targetBackend(): TargetBackend =
when (fragmentCompilerBackend()) {
CodeFragmentCompiler.Companion.FragmentCompilerBackend.JVM ->
if (useIrBackend()) TargetBackend.JVM_IR_WITH_OLD_EVALUATOR else TargetBackend.JVM_WITH_OLD_EVALUATOR
CodeFragmentCompiler.Companion.FragmentCompilerBackend.JVM_IR ->
if (useIrBackend()) TargetBackend.JVM_IR_WITH_IR_EVALUATOR else TargetBackend.JVM_WITH_IR_EVALUATOR
}
protected fun getExpectedOutputFile(): File {
if (useIrBackend()) {
val irOut = File(getTestDirectoryPath(), getTestName(true) + ".ir.out")
@@ -9,6 +9,7 @@ import com.intellij.testFramework.TestDataPath;
import org.jetbrains.kotlin.test.JUnit3RunnerWithInners;
import org.jetbrains.kotlin.test.KotlinTestUtils;
import org.jetbrains.kotlin.test.util.KtTestUtil;
import org.jetbrains.kotlin.test.TargetBackend;
import org.jetbrains.kotlin.test.TestMetadata;
import org.junit.runner.RunWith;
@@ -24,7 +25,7 @@ public class KotlinEvaluateExpressionTestGenerated extends AbstractKotlinEvaluat
@RunWith(JUnit3RunnerWithInners.class)
public static class SingleBreakpoint extends AbstractKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doSingleBreakpointTest, this, testDataFilePath);
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_WITH_OLD_EVALUATOR, testDataFilePath);
}
@TestMetadata("abstractFunCall.kt")
@@ -38,7 +39,7 @@ public class KotlinEvaluateExpressionTestGenerated extends AbstractKotlinEvaluat
}
public void testAllFilesPresentInSingleBreakpoint() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint"), Pattern.compile("^(.+)\\.kt$"), null, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("annotationValue.kt")
@@ -96,6 +97,11 @@ public class KotlinEvaluateExpressionTestGenerated extends AbstractKotlinEvaluat
runTest("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/collections.kt");
}
@TestMetadata("color.kt")
public void testColor() throws Exception {
runTest("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/color.kt");
}
@TestMetadata("dataClassCopy.kt")
public void testDataClassCopy() throws Exception {
runTest("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/dataClassCopy.kt");
@@ -526,11 +532,11 @@ public class KotlinEvaluateExpressionTestGenerated extends AbstractKotlinEvaluat
@RunWith(JUnit3RunnerWithInners.class)
public static class CompilingEvaluator extends AbstractKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doSingleBreakpointTest, this, testDataFilePath);
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInCompilingEvaluator() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/compilingEvaluator"), Pattern.compile("^(.+)\\.kt$"), null, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/compilingEvaluator"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("ceAnonymousObject.kt")
@@ -594,11 +600,11 @@ public class KotlinEvaluateExpressionTestGenerated extends AbstractKotlinEvaluat
@RunWith(JUnit3RunnerWithInners.class)
public static class Coroutines extends AbstractKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doSingleBreakpointTest, this, testDataFilePath);
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInCoroutines() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/coroutines"), Pattern.compile("^(.+)\\.kt$"), null, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/coroutines"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("anyUpdateInvokeStatic.kt")
@@ -647,11 +653,11 @@ public class KotlinEvaluateExpressionTestGenerated extends AbstractKotlinEvaluat
@RunWith(JUnit3RunnerWithInners.class)
public static class CreateExpression extends AbstractKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doSingleBreakpointTest, this, testDataFilePath);
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInCreateExpression() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/createExpression"), Pattern.compile("^(.+)\\.kt$"), null, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/createExpression"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("createExpressionCastToBuiltIn.kt")
@@ -675,11 +681,11 @@ public class KotlinEvaluateExpressionTestGenerated extends AbstractKotlinEvaluat
@RunWith(JUnit3RunnerWithInners.class)
public static class ExtraVariables extends AbstractKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doSingleBreakpointTest, this, testDataFilePath);
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInExtraVariables() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/extraVariables"), Pattern.compile("^(.+)\\.kt$"), null, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/extraVariables"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("evBreakpointOnPropertyDeclaration.kt")
@@ -743,11 +749,11 @@ public class KotlinEvaluateExpressionTestGenerated extends AbstractKotlinEvaluat
@RunWith(JUnit3RunnerWithInners.class)
public static class Frame extends AbstractKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doSingleBreakpointTest, this, testDataFilePath);
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInFrame() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/frame"), Pattern.compile("^(.+)\\.kt$"), null, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/frame"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("capturedValues1.kt")
@@ -996,11 +1002,11 @@ public class KotlinEvaluateExpressionTestGenerated extends AbstractKotlinEvaluat
@RunWith(JUnit3RunnerWithInners.class)
public static class JavaContext extends AbstractKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doSingleBreakpointTest, this, testDataFilePath);
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInJavaContext() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/javaContext"), Pattern.compile("^(.+)\\.kt$"), null, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/javaContext"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("jcBlock.kt")
@@ -1039,11 +1045,11 @@ public class KotlinEvaluateExpressionTestGenerated extends AbstractKotlinEvaluat
@RunWith(JUnit3RunnerWithInners.class)
public static class Labels extends AbstractKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doSingleBreakpointTest, this, testDataFilePath);
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInLabels() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/labels"), Pattern.compile("^(.+)\\.kt$"), null, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/labels"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("lCallOnLabeledObj.kt")
@@ -1077,11 +1083,11 @@ public class KotlinEvaluateExpressionTestGenerated extends AbstractKotlinEvaluat
@RunWith(JUnit3RunnerWithInners.class)
public static class Lambdas extends AbstractKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doSingleBreakpointTest, this, testDataFilePath);
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInLambdas() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/lambdas"), Pattern.compile("^(.+)\\.kt$"), null, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/lambdas"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("destructuringParam.kt")
@@ -1140,11 +1146,11 @@ public class KotlinEvaluateExpressionTestGenerated extends AbstractKotlinEvaluat
@RunWith(JUnit3RunnerWithInners.class)
public static class Renderer extends AbstractKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doSingleBreakpointTest, this, testDataFilePath);
KotlinTestUtils.runTest(this::doSingleBreakpointTest, TargetBackend.JVM_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInRenderer() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/renderer"), Pattern.compile("^(.+)\\.kt$"), null, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/singleBreakpoint/renderer"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("toStringRenderer.kt")
@@ -1159,11 +1165,11 @@ public class KotlinEvaluateExpressionTestGenerated extends AbstractKotlinEvaluat
@RunWith(JUnit3RunnerWithInners.class)
public static class MultipleBreakpoints extends AbstractKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doMultipleBreakpointsTest, this, testDataFilePath);
KotlinTestUtils.runTest(this::doMultipleBreakpointsTest, TargetBackend.JVM_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInMultipleBreakpoints() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/multipleBreakpoints"), Pattern.compile("^(.+)\\.kt$"), null, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/multipleBreakpoints"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("clearCache.kt")
@@ -1296,11 +1302,11 @@ public class KotlinEvaluateExpressionTestGenerated extends AbstractKotlinEvaluat
@RunWith(JUnit3RunnerWithInners.class)
public static class Library extends AbstractKotlinEvaluateExpressionTest {
private void runTest(String testDataFilePath) throws Exception {
KotlinTestUtils.runTest(this::doMultipleBreakpointsTest, this, testDataFilePath);
KotlinTestUtils.runTest(this::doMultipleBreakpointsTest, TargetBackend.JVM_WITH_OLD_EVALUATOR, testDataFilePath);
}
public void testAllFilesPresentInLibrary() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/multipleBreakpoints/library"), Pattern.compile("^(.+)\\.kt$"), null, true);
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/jvm-debugger/jvm-debugger-test/testData/evaluation/multipleBreakpoints/library"), Pattern.compile("^(.+)\\.kt$"), null, TargetBackend.JVM_WITH_OLD_EVALUATOR, true);
}
@TestMetadata("customLibClassName.kt")
@@ -24,7 +24,7 @@ internal class KotlinOutputChecker(
private val testDir: String,
appPath: String,
outputPath: String,
private val useIrBackend: Boolean,
private val targetBackend: TargetBackend,
private val expectedOutputFile: File,
) : OutputChecker(appPath, outputPath) {
companion object {
@@ -63,7 +63,7 @@ internal class KotlinOutputChecker(
val outDir = File(testDir)
var outFile = expectedOutputFile
val isIgnored = InTextDirectivesUtils.isIgnoredTarget(if (useIrBackend) TargetBackend.JVM_IR else TargetBackend.JVM, outFile)
val isIgnored = outFile.exists() && InTextDirectivesUtils.isIgnoredTarget(targetBackend, outFile)
if (!outFile.exists()) {
if (SystemInfo.isWindows) {
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at clearCache.kt:12
LineBreakpoint created at clearCache.kt:20
LineBreakpoint created at clearCache.kt:31
@@ -1,4 +1,5 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
// IGNORE_BACKEND: JVM_IR_WITH_OLD_EVALUATOR
FunctionBreakpoint created at constructors.kt:9
LineBreakpoint created at constructors.kt:13
FunctionBreakpoint created at constructors.kt:20
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at exceptions.kt:9
LineBreakpoint created at exceptions.kt:14
LineBreakpoint created at exceptions.kt:26
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at extensionMemberFunction.kt:13
LineBreakpoint created at extensionMemberFunction.kt:19
LineBreakpoint created at extensionMemberFunction.kt:25
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at extensionMemberFunctionInObject.kt:14
LineBreakpoint created at extensionMemberFunctionInObject.kt:20
Run Java
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at extensionMemberProperty.kt:13
LineBreakpoint created at extensionMemberProperty.kt:19
LineBreakpoint created at extensionMemberProperty.kt:25
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at fieldVariable.kt:7
LineBreakpoint created at fieldVariable.kt:14
Run Java
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at funFromOuterClassInLamdba.kt:20
LineBreakpoint created at funFromOuterClassInLamdba.kt:28
LineBreakpoint created at funFromOuterClassInLamdba.kt:36
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at initializer.kt:12
LineBreakpoint created at initializer.kt:18 lambdaOrdinal = -1
Run Java
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at invisibleDeclarations.kt:16
Run Java
Connected to the target VM
@@ -1,4 +1,5 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
// IGNORE_BACKEND: JVM_IR_WITH_OLD_EVALUATOR
LineBreakpoint created at isInsideInlineLambdaInLibrary.kt:7 lambdaOrdinal = 1
LineBreakpoint created at isInsideInlineLambdaInLibrary.kt:12 lambdaOrdinal = 1
LineBreakpoint created at isInsideInlineLambdaInLibrary.kt:18 lambdaOrdinal = 1
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at lambdaParameters.kt:5
LineBreakpoint created at lambdaParameters.kt:10
Run Java
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at a1.kt:7
LineBreakpoint created at a1.kt:7
LineBreakpoint created at a1.kt:7
@@ -1,4 +1,5 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
// IGNORE_BACKEND: JVM_IR_WITH_OLD_EVALUATOR
LineBreakpoint created at localFunCustomLib.kt:7
Run Java
Connected to the target VM
@@ -1,4 +1,5 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
// IGNORE_BACKEND: JVM_IR_WITH_OLD_EVALUATOR
LineBreakpoint created at localFun.kt:9
LineBreakpoint created at localFun.kt:15
LineBreakpoint created at localFun.kt:21
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at multipleBreakpointsAtLine.kt:9 lambdaOrdinal = -1
LineBreakpoint created at multipleBreakpointsAtLine.kt:14 lambdaOrdinal = 1
LineBreakpoint created at multipleBreakpointsAtLine.kt:19 lambdaOrdinal = 2
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at mutations.kt:8
LineBreakpoint created at mutations.kt:11
LineBreakpoint created at mutations.kt:14
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at nonCapturedVariables.kt:8
LineBreakpoint created at nonCapturedVariables.kt:12
LineBreakpoint created at nonCapturedVariables.kt:16
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at privateMembersPriority.kt:21
LineBreakpoint created at privateMembersPriority.kt:33
LineBreakpoint created at privateMembersPriority.kt:40
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at remappedParameterInInline.kt:11
Run Java
Connected to the target VM
@@ -1,4 +1,5 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
// IGNORE_BACKEND: JVM_IR_WITH_OLD_EVALUATOR
LineBreakpoint created at smartcasts.kt:19
LineBreakpoint created at smartcasts.kt:29
Run Java
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at thisLabels.kt:6
LineBreakpoint created at thisLabels.kt:8
LineBreakpoint created at thisLabels.kt:10
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at whenEntry.kt:10
LineBreakpoint created at whenEntry.kt:18
LineBreakpoint created at whenEntry.kt:26
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
FunctionBreakpoint created at withoutBodyFunctions.kt:9
FunctionBreakpoint created at withoutBodyFunctions.kt:15
LineBreakpoint created at withoutBodyFunctions.kt:21
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
KotlinFieldBreakpoint created at withoutBodyProperties.kt:8
KotlinFieldBreakpoint created at withoutBodyProperties.kt:13
LineBreakpoint created at withoutBodyProperties.kt:21
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
KotlinFieldBreakpoint created at withoutBodyProperties2.kt:8
KotlinFieldBreakpoint created at withoutBodyProperties2.kt:13
Run Java
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
FunctionBreakpoint created at withoutBodyTypeParameters.kt:8
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at .kt.kt:5
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at abstractFunCall.kt:5
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at accessToOverridenPropertyWithBackingField.kt:12
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at annotationValue.kt:10
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at anonymousObjects.kt:11
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at arrayMethods.kt:5
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at arrays.kt:5
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at boxParam.kt:13
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at boxReturnValue.kt:7
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at callableBug.kt:8 lambdaOrdinal = 1
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at classFromAnotherPackage.kt:8
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at classObjectVal.kt:10
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at collections.kt:6
Run Java
Connected to the target VM
@@ -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
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at ceAnonymousObject.kt:18
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at ceAnonymousObjectCapturedInClosure.kt:7 lambdaOrdinal = -1
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at ceAnonymousObjectThisAsReceiver.kt:9
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at ceLambda.kt:6
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at ceLocalClass.kt:6
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at ceLocalClassMembers.kt:19
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at ceLocalClassWithSuperClass.kt:19
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at ceMembers.kt:19
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at ceObject.kt:5
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at ceSeveralLambdas.kt:5
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at ceSuperAccess.kt:20
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at anyUpdateInvokeStatic.kt:25
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at anyUpdateVariable.kt:22
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at capturedReceiverName.kt:22
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at primitivesCoertion.kt:10
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at stringUpdateInvokeStatic.kt:25
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at stringUpdateInvokeVirtual.kt:24
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at stringUpdatePutField.kt:24
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at stringUpdateVariable.kt:22
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at createExpressionCastToBuiltIn.kt:7
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at createExpressionWithArray.kt:12
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at dataClassCopy.kt:6
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at defaultParameterValues.kt:10
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at defaultParameterValues2.kt:9
Run Java
Connected to the target VM
@@ -1,4 +1,5 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
// IGNORE_BACKEND: JVM_IR_WITH_OLD_EVALUATOR
LineBreakpoint created at delegatedPropertyInOtherFile.kt:10
Run Java
Connected to the target VM
@@ -1,4 +1,5 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
// IGNORE_BACKEND: JVM_IR_WITH_OLD_EVALUATOR
LineBreakpoint created at delegatedVariables.kt:6
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at dependentOnFile.kt:7
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at doubles.kt:7
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at enums.kt:7
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at errors.kt:13
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at escapedNames.kt:6
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at experimentalApi.kt:11
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at evDelegatedProperty.kt:13
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at extractLocalVariables.kt:7
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at extractThis.kt:13
Run Java
Connected to the target VM
@@ -1,4 +1,5 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
// IGNORE_BACKEND: JVM_IR_WITH_OLD_EVALUATOR
LineBreakpoint created at extractThisInTrait.kt:10
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at extractVariablesFromCall.kt:8
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at fieldGetters.kt:9
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at fileWithInternal.kt:6
Run Java
Connected to the target VM
@@ -1,4 +1,4 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JVM_IR_WITH_OLD_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at capturedValues1.kt:17
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR
LineBreakpoint created at catchVariable.kt:9
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at coroutineContextFun.kt:9
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at coroutineContextLambda.kt:15
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at coroutineContextWithoutSuspend.kt:11
Run Java
Connected to the target VM
@@ -1,4 +1,5 @@
// IGNORE_BACKEND: JVM_IR
// IGNORE_BACKEND: JVM_WITH_IR_EVALUATOR, JVM_IR_WITH_IR_EVALUATOR
// IGNORE_BACKEND: JVM_IR_WITH_OLD_EVALUATOR
LineBreakpoint created at defaultImplsMangling.kt:8
Run Java
Connected to the target VM
@@ -1,3 +1,4 @@
// IGNORE_BACKEND: JVM_IR_WITH_IR_EVALUATOR
LineBreakpoint created at delegatedPropertyInClass.kt:9
Run Java
Connected to the target VM

Some files were not shown because too many files have changed in this diff Show More