Minor cleanup: avoid vague util names
This commit is contained in:
committed by
Dmitriy Novozhilov
parent
8b24f4b5c6
commit
8368812432
+2
-14
@@ -75,19 +75,7 @@ internal fun checkExpectDeclarationVisibilityAndBody(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
internal fun checkProperty(
|
internal fun checkPropertyInitializer(
|
||||||
containingClass: FirRegularClass?,
|
|
||||||
property: FirProperty,
|
|
||||||
modifierList: FirModifierList?,
|
|
||||||
isInitialized: Boolean,
|
|
||||||
reporter: DiagnosticReporter,
|
|
||||||
context: CheckerContext
|
|
||||||
) {
|
|
||||||
checkPropertyInitializer(containingClass, property, modifierList, isInitialized, reporter, context)
|
|
||||||
checkPropertyAccessors(property, reporter, context)
|
|
||||||
}
|
|
||||||
|
|
||||||
private fun checkPropertyInitializer(
|
|
||||||
containingClass: FirRegularClass?,
|
containingClass: FirRegularClass?,
|
||||||
property: FirProperty,
|
property: FirProperty,
|
||||||
modifierList: FirModifierList?,
|
modifierList: FirModifierList?,
|
||||||
@@ -166,7 +154,7 @@ private fun checkPropertyInitializer(
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun checkPropertyAccessors(
|
internal fun checkPropertyAccessors(
|
||||||
property: FirProperty,
|
property: FirProperty,
|
||||||
reporter: DiagnosticReporter,
|
reporter: DiagnosticReporter,
|
||||||
context: CheckerContext
|
context: CheckerContext
|
||||||
|
|||||||
+2
-1
@@ -148,7 +148,8 @@ object FirMemberPropertiesChecker : FirRegularClassChecker() {
|
|||||||
// So, our source of truth should be the full modifier list retrieved from the source.
|
// So, our source of truth should be the full modifier list retrieved from the source.
|
||||||
val modifierList = with(FirModifierList) { property.source.getModifierList() }
|
val modifierList = with(FirModifierList) { property.source.getModifierList() }
|
||||||
|
|
||||||
checkProperty(containingDeclaration, property, modifierList, isInitialized, reporter, context)
|
checkPropertyInitializer(containingDeclaration, property, modifierList, isInitialized, reporter, context)
|
||||||
|
checkPropertyAccessors(property, reporter, context)
|
||||||
checkExpectDeclarationVisibilityAndBody(property, source, reporter, context)
|
checkExpectDeclarationVisibilityAndBody(property, source, reporter, context)
|
||||||
|
|
||||||
val hasAbstractModifier = modifierList?.modifiers?.any { it.token == KtTokens.ABSTRACT_KEYWORD } == true
|
val hasAbstractModifier = modifierList?.modifiers?.any { it.token == KtTokens.ABSTRACT_KEYWORD } == true
|
||||||
|
|||||||
+2
-1
@@ -28,7 +28,8 @@ object FirTopLevelPropertiesChecker : FirFileChecker() {
|
|||||||
// So, our source of truth should be the full modifier list retrieved from the source.
|
// So, our source of truth should be the full modifier list retrieved from the source.
|
||||||
val modifierList = with(FirModifierList) { source.getModifierList() }
|
val modifierList = with(FirModifierList) { source.getModifierList() }
|
||||||
|
|
||||||
checkProperty(null, property, modifierList, property.initializer != null, reporter, context)
|
checkPropertyInitializer(null, property, modifierList, property.initializer != null, reporter, context)
|
||||||
|
checkPropertyAccessors(property, reporter, context)
|
||||||
checkExpectDeclarationVisibilityAndBody(property, source, reporter, context)
|
checkExpectDeclarationVisibilityAndBody(property, source, reporter, context)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user