Fix build.
This commit is contained in:
@@ -300,6 +300,8 @@ private fun createKeywordWithLabelElement(keyword: String, label: String?): Look
|
||||
|
||||
fun breakOrContinueExpressionItems(position: JetElement, breakOrContinue: String): Collection<LookupElement> {
|
||||
val result = ArrayList<LookupElement>()
|
||||
|
||||
@parentsLoop
|
||||
for (parent in position.parents()) {
|
||||
when (parent) {
|
||||
is JetLoopExpression -> {
|
||||
@@ -313,7 +315,7 @@ fun breakOrContinueExpressionItems(position: JetElement, breakOrContinue: String
|
||||
}
|
||||
}
|
||||
|
||||
is JetDeclarationWithBody -> break //TODO: support non-local break's&continue's when they are supported by compiler
|
||||
is JetDeclarationWithBody -> break@parentsLoop //TODO: support non-local break's&continue's when they are supported by compiler
|
||||
}
|
||||
}
|
||||
return result
|
||||
|
||||
@@ -56,6 +56,8 @@ public class SyntheticKotlinBlock(
|
||||
override fun toString(): String {
|
||||
var child = subBlocks.first()
|
||||
var treeNode: ASTNode? = null
|
||||
|
||||
@loop
|
||||
while (treeNode == null) when (child) {
|
||||
is AbstractBlock -> {
|
||||
treeNode = (child as AbstractBlock).getNode()
|
||||
@@ -63,7 +65,7 @@ public class SyntheticKotlinBlock(
|
||||
is SyntheticKotlinBlock -> {
|
||||
child = (child as SyntheticKotlinBlock).getSubBlocks().first()
|
||||
}
|
||||
else -> break
|
||||
else -> break@loop
|
||||
}
|
||||
|
||||
val textRange = getTextRange()
|
||||
|
||||
+3
-1
@@ -506,12 +506,14 @@ class CallableBuilder(val config: CallableBuilderConfiguration) {
|
||||
fun calcNecessaryEmptyLines(decl: JetDeclaration, after: Boolean): Int {
|
||||
var lineBreaksPresent: Int = 0
|
||||
var neighbor: PsiElement? = null
|
||||
|
||||
@siblingsLoop
|
||||
for (sibling in decl.siblings(forward = after, withItself = false)) {
|
||||
when (sibling) {
|
||||
is PsiWhiteSpace -> lineBreaksPresent += (sibling.getText() ?: "").count { it == '\n' }
|
||||
else -> {
|
||||
neighbor = sibling
|
||||
break
|
||||
break@siblingsLoop
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+3
-1
@@ -90,6 +90,8 @@ public fun processDuplicates(
|
||||
if (answer != Messages.YES) return
|
||||
|
||||
var showAll = false
|
||||
|
||||
@duplicateReplacersLoop
|
||||
for ((i, entry) in duplicateReplacers.entrySet().withIndex()) {
|
||||
val (pattern, replacer) = entry
|
||||
if (!pattern.isValid()) continue
|
||||
@@ -101,7 +103,7 @@ public fun processDuplicates(
|
||||
promptDialog.show()
|
||||
when(promptDialog.getExitCode()) {
|
||||
FindManager.PromptResult.ALL -> showAll = true
|
||||
FindManager.PromptResult.SKIP -> continue
|
||||
FindManager.PromptResult.SKIP -> continue@duplicateReplacersLoop
|
||||
FindManager.PromptResult.CANCEL -> return
|
||||
}
|
||||
}
|
||||
|
||||
@@ -34,9 +34,10 @@ object DocCommentConverter {
|
||||
val html = StringBuilder {
|
||||
appendJavadocElements(docComment.getDescriptionElements())
|
||||
|
||||
@tagsLoop
|
||||
for (tag in docComment.getTags()) {
|
||||
when (tag.getName()) {
|
||||
"deprecated" -> continue
|
||||
"deprecated" -> continue@tagsLoop
|
||||
"see" -> append("@see ${convertJavadocLink(tag.content())}\n")
|
||||
else -> appendJavadocElements(tag.getChildren()).append("\n")
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user