mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
Fix issue when break added into wrong code block
This commit is contained in:
+1
-1
@@ -20,5 +20,5 @@ package com.intellij.debugger.streams.trace.dsl
|
||||
*/
|
||||
interface ForLoopBody : CodeBlock {
|
||||
val loopVariable: Variable
|
||||
fun breakIteration()
|
||||
fun breakIteration(): Expression
|
||||
}
|
||||
+2
-1
@@ -15,6 +15,7 @@
|
||||
*/
|
||||
package com.intellij.debugger.streams.trace.dsl.impl.java
|
||||
|
||||
import com.intellij.debugger.streams.trace.dsl.Expression
|
||||
import com.intellij.debugger.streams.trace.dsl.ForLoopBody
|
||||
import com.intellij.debugger.streams.trace.dsl.StatementFactory
|
||||
import com.intellij.debugger.streams.trace.dsl.Variable
|
||||
@@ -29,5 +30,5 @@ class JavaForLoopBody(statementFactory: StatementFactory, override val loopVaria
|
||||
val BREAK = TextExpression("break")
|
||||
}
|
||||
|
||||
override fun breakIteration() = addStatement(BREAK)
|
||||
override fun breakIteration(): Expression = BREAK
|
||||
}
|
||||
+2
-7
@@ -15,10 +15,7 @@
|
||||
*/
|
||||
package com.intellij.debugger.streams.trace.dsl.impl.kotlin
|
||||
|
||||
import com.intellij.debugger.streams.trace.dsl.Dsl
|
||||
import com.intellij.debugger.streams.trace.dsl.ForLoopBody
|
||||
import com.intellij.debugger.streams.trace.dsl.StatementFactory
|
||||
import com.intellij.debugger.streams.trace.dsl.Variable
|
||||
import com.intellij.debugger.streams.trace.dsl.*
|
||||
import com.intellij.debugger.streams.trace.dsl.impl.TextExpression
|
||||
|
||||
/**
|
||||
@@ -30,7 +27,5 @@ class KotlinForLoopBody(override val loopVariable: Variable,
|
||||
val BREAK = TextExpression("break")
|
||||
}
|
||||
|
||||
override fun breakIteration() {
|
||||
addStatement(BREAK)
|
||||
}
|
||||
override fun breakIteration(): Expression = BREAK
|
||||
}
|
||||
Reference in New Issue
Block a user