Minor refactoring
This commit is contained in:
@@ -86,7 +86,7 @@ class InflowSlicer(
|
||||
}
|
||||
|
||||
private fun processParameter(parameter: KtParameter, includeOverriders: Boolean) {
|
||||
if (!parameter.canProcess()) return
|
||||
if (!canProcessParameter(parameter)) return
|
||||
|
||||
val function = parameter.ownerFunction ?: return
|
||||
|
||||
|
||||
@@ -35,7 +35,7 @@ class OutflowSlicer(
|
||||
}
|
||||
|
||||
private fun processVariable(variable: KtCallableDeclaration) {
|
||||
if (variable is KtParameter && !variable.canProcess()) return
|
||||
if (variable is KtParameter && !canProcessParameter(variable)) return
|
||||
|
||||
val withDereferences = parentUsage.params.showInstanceDereferences
|
||||
val accessKind = if (withDereferences) AccessKind.READ_OR_WRITE else AccessKind.READ_ONLY
|
||||
|
||||
@@ -130,7 +130,7 @@ abstract class Slicer(
|
||||
}
|
||||
}
|
||||
|
||||
protected fun KtParameter.canProcess() = !isVarArg
|
||||
protected fun canProcessParameter(parameter: KtParameter) = !parameter.isVarArg
|
||||
|
||||
protected val DeclarationDescriptorWithSource.originalSource: SourceElement
|
||||
get() {
|
||||
|
||||
Reference in New Issue
Block a user