-
Notifications
You must be signed in to change notification settings - Fork 66
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adding coroutines to analysis process #128
base: master
Are you sure you want to change the base?
Conversation
import kotlinx.coroutines.runBlocking | ||
import kotlin.coroutines.CoroutineContext | ||
|
||
object KotlinCoroutinesScope : CoroutineScope { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I really don't like name of this object.
It can by KotlinAnalyzisScope
or KotlinSupervisedScope
if we want to use it somewhere else.
@@ -30,13 +30,13 @@ import org.jetbrains.kotlin.progress.CompilationCanceledException | |||
import org.jetbrains.kotlin.progress.CompilationCanceledStatus | |||
import org.jetbrains.kotlin.progress.ProgressIndicatorAndCompilationCanceledStatus | |||
|
|||
public class KotlinAnalysisJob(private val javaProject: IJavaProject) : Job("Kotlin Analysis") { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Remove this class as it doesn't have any purpose now.
@@ -97,14 +100,18 @@ class KotlinBuilder : IncrementalProjectBuilder() { | |||
val ktFiles = existingAffectedFiles.map { KotlinPsiManager.getParsedFile(it) } | |||
|
|||
val analysisResultWithProvider = if (ktFiles.isEmpty()) | |||
KotlinAnalyzer.analyzeProject(project) | |||
runBlocking { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
runBlocking
here is completely unnecessary.
No description provided.