[FIR] Refactor effective visibility calculation
Before this commit, we had effective visibility as a part of FIR status, so it was integrated into the full pipeline. In this commit, we introduced "effective visibility as a service" which is now used only by exposed visibility checker. This allows us to make the thing universal for all FIR nodes, including nodes for Java / deserialized.
This commit is contained in:
@@ -1,13 +0,0 @@
|
||||
abstract class Outer {
|
||||
protected open class My
|
||||
// Both valid: same way protected
|
||||
protected class Your: My()
|
||||
abstract protected fun foo(my: My): Your
|
||||
}
|
||||
|
||||
class OuterDerived: Outer() {
|
||||
// valid, My has better visibility
|
||||
protected class His: Outer.My()
|
||||
// valid, My and Your have better visibility
|
||||
override fun <!EXPOSED_FUNCTION_RETURN_TYPE!>foo<!>(<!EXPOSED_PARAMETER_TYPE!>my: Outer.My<!>) = Outer.Your()
|
||||
}
|
||||
@@ -1,3 +1,4 @@
|
||||
// FIR_IDENTICAL
|
||||
abstract class Outer {
|
||||
protected open class My
|
||||
// Both valid: same way protected
|
||||
|
||||
Reference in New Issue
Block a user