Skip to content

Commit 62ebcaa

Browse files
Vassiliy-Kudryashovtamarinvs19
authored andcommitted
Switch from implicit disposable to explicit wrapper (#1602)
Add return@label for Computable-in-Computable ambiguity
1 parent bc11514 commit 62ebcaa

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

utbot-intellij/src/main/kotlin/org/utbot/intellij/plugin/generator/IntentionHelper.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,10 @@ class IntentionHelper(val project: Project, private val editor: Editor, private
2424
val actions =
2525
DumbService.getInstance(project).runReadActionInSmartMode(Computable<Map<IntentionAction, String>> {
2626
val daemonProgressIndicator = DaemonProgressIndicator()
27-
Disposer.register(project, daemonProgressIndicator)//check it
28-
val list = ProgressManager.getInstance().runProcess(Computable<List<HighlightInfo>> {
27+
Disposer.register(project) { daemonProgressIndicator.cancel() }//check it
28+
val list = ProgressManager.getInstance().runProcess(Computable<List<HighlightInfo>> inner@{
2929
try {
30-
val containingFile = testFile.containingFile ?: return@Computable emptyList()
30+
val containingFile = testFile.containingFile ?: return@inner emptyList()
3131
DaemonCodeAnalyzerEx.getInstanceEx(project).runMainPasses(
3232
containingFile,
3333
editor.document,

0 commit comments

Comments
 (0)