FIR: fix lookup tracking in conflicts checker for LT
since it relies on the correct context declaration
This commit is contained in:
+5
@@ -222,6 +222,8 @@ object FirConflictsChecker : FirBasicDeclarationChecker() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
context.addDeclaration(declaration)
|
||||||
|
try {
|
||||||
inspector.declarationConflictingSymbols.forEach { (conflictingDeclaration, symbols) ->
|
inspector.declarationConflictingSymbols.forEach { (conflictingDeclaration, symbols) ->
|
||||||
val source = conflictingDeclaration.source
|
val source = conflictingDeclaration.source
|
||||||
if (source != null && symbols.isNotEmpty()) {
|
if (source != null && symbols.isNotEmpty()) {
|
||||||
@@ -260,6 +262,9 @@ object FirConflictsChecker : FirBasicDeclarationChecker() {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
} finally {
|
||||||
|
context.dropDeclaration()
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
private fun checkConflictingParameters(parameters: List<FirElement>, context: CheckerContext, reporter: DiagnosticReporter) {
|
private fun checkConflictingParameters(parameters: List<FirElement>, context: CheckerContext, reporter: DiagnosticReporter) {
|
||||||
|
|||||||
Reference in New Issue
Block a user