Skip to content

Commit 92c2d17

Browse files
committed
Cleanup leftovers in compiler and IDE
1 parent 3d5e415 commit 92c2d17

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

compiler/daemon/src/org/jetbrains/kotlin/daemon/LazyClasspathWatcher.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ class LazyClasspathWatcher(classpath: Iterable<String>,
5656
init {
5757
// locking before entering thread in order to avoid racing with isChanged
5858
fileIdsLock.acquire()
59-
thread(daemon = true, start = true) {
59+
thread(isDaemon = true, start = true) {
6060
try {
6161
fileIds = classpath
6262
.map { File(it) }

idea/idea-completion/src/org/jetbrains/kotlin/idea/completion/handlers/GenerateLambda.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ private fun needExplicitParameterTypes(context: InsertionContext, placeholderRan
8888
if (functionTypes.size <= 1) return false
8989

9090
val lambdaParameterCount = KotlinBuiltIns.getParameterTypeProjectionsFromFunctionType(lambdaType).size
91-
return functionTypes.filter { KotlinBuiltIns.getParameterTypeProjectionsFromFunctionType(it).size() == lambdaParameterCount }.size > 1
91+
return functionTypes.filter { KotlinBuiltIns.getParameterTypeProjectionsFromFunctionType(it).size == lambdaParameterCount }.size > 1
9292
}
9393

9494
private fun buildTemplate(lambdaType: KotlinType, explicitParameterTypes: Boolean, project: Project): Template {

idea/src/org/jetbrains/kotlin/idea/inspections/RedundantSamConstructorInspection.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ class RedundantSamConstructorInspection : AbstractKotlinInspection() {
7979

8080
val samConstructorCalls = samConstructorCallsToBeConverted(expression)
8181
if (samConstructorCalls.isEmpty()) return
82-
if (samConstructorCalls.size() == 1) {
82+
if (samConstructorCalls.size == 1) {
8383
val single = samConstructorCalls.single()
8484
val problemDescriptor = holder.manager.
8585
createProblemDescriptor(single.calleeExpression!!,
@@ -177,7 +177,7 @@ class RedundantSamConstructorInspection : AbstractKotlinInspection() {
177177
// SAM adapters for static functions
178178
for (staticFunWithSameName in containingClass.staticScope.getContributedFunctions(functionResolvedCall.resultingDescriptor.name, NoLookupLocation.FROM_IDE)) {
179179
if (staticFunWithSameName is SamAdapterDescriptor<*>) {
180-
if (isSamAdapterSuitableForCall(staticFunWithSameName, originalFunctionDescriptor, samConstructorCallArguments.size())) {
180+
if (isSamAdapterSuitableForCall(staticFunWithSameName, originalFunctionDescriptor, samConstructorCallArguments.size)) {
181181
return samConstructorCallArguments.check { canBeReplaced(functionCall, it) } ?: emptyList()
182182
}
183183
}
@@ -191,7 +191,7 @@ class RedundantSamConstructorInspection : AbstractKotlinInspection() {
191191
NoLookupLocation.FROM_IDE)
192192
for (syntheticExtension in syntheticExtensions) {
193193
val samAdapter = syntheticExtension as? SamAdapterExtensionFunctionDescriptor ?: continue
194-
if (isSamAdapterSuitableForCall(samAdapter, originalFunctionDescriptor, samConstructorCallArguments.size())) {
194+
if (isSamAdapterSuitableForCall(samAdapter, originalFunctionDescriptor, samConstructorCallArguments.size)) {
195195
return samConstructorCallArguments.check { canBeReplaced(functionCall, it) } ?: emptyList()
196196
}
197197
}

0 commit comments

Comments
 (0)