[FIR] Check for setter visibility in resolution stage
This is required for the following commit where candidates from the original scope in presence of smart cast will not be ignored if they're the same symbol.
This commit is contained in:
committed by
Space Team
parent
737b286d5c
commit
5186ba80e2
+2
@@ -86,6 +86,8 @@ object HiddenCandidate : ResolutionDiagnostic(HIDDEN)
|
||||
|
||||
object VisibilityError : ResolutionDiagnostic(K2_VISIBILITY_ERROR)
|
||||
|
||||
object SetterVisibilityError : ResolutionDiagnostic(K2_VISIBILITY_ERROR)
|
||||
|
||||
object ResolvedWithLowPriority : ResolutionDiagnostic(RESOLVED_LOW_PRIORITY)
|
||||
|
||||
object ResolvedWithSynthetic : ResolutionDiagnostic(K2_SYNTHETIC_RESOLVED)
|
||||
|
||||
+6
@@ -111,6 +111,12 @@ open class ConeVisibilityError(
|
||||
override val reason: String get() = "HIDDEN: ${describeSymbol(symbol)} is invisible"
|
||||
}
|
||||
|
||||
open class ConeSetterVisibilityError(
|
||||
override val symbol: FirPropertySymbol
|
||||
) : ConeDiagnosticWithSymbol<FirBasedSymbol<*>> {
|
||||
override val reason: String get() = "HIDDEN SETTER: ${describeSymbol(symbol)} is invisible"
|
||||
}
|
||||
|
||||
class ConeTypeVisibilityError(
|
||||
symbol: FirBasedSymbol<*>,
|
||||
val smallestUnresolvablePrefix: List<FirQualifierPart>,
|
||||
|
||||
Reference in New Issue
Block a user