[FIR] Initialize public visibility for class-like declarations at FIR building phase if no modifier is presented
Java resolving subsystem requires calculated visibility for correct disambiguation of supertypes. But visibility remains `Unknown` for Kotlin class-like declarations during supertypes resolving because `STATUS` resolve phase is performed after `SUPER_TYPES` phase. To fix the problem, the visibility should be initialized to public at the FIR building phase if no modifier is presented. ^KT-64127 Fixed
This commit is contained in:
committed by
Space Team
parent
ee8d42532b
commit
69b9bfc3e0
@@ -1,181 +1,181 @@
|
||||
RAW_FIR:
|
||||
FILE: [ResolvedTo(RAW_FIR)] cyclicHierarchy2.kt
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface ResolveMe : A, E {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface ResolveMe : A, E {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface C : ResolveMe {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface C : ResolveMe {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface D : ResolveMe {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface D : ResolveMe {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface E : F {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface E : F {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface F : D, C {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface F : D, C {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
}
|
||||
|
||||
IMPORTS:
|
||||
FILE: [ResolvedTo(IMPORTS)] cyclicHierarchy2.kt
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface ResolveMe : A, E {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface ResolveMe : A, E {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface C : ResolveMe {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface C : ResolveMe {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface D : ResolveMe {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface D : ResolveMe {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface E : F {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface E : F {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface F : D, C {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface F : D, C {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
}
|
||||
|
||||
COMPILER_REQUIRED_ANNOTATIONS:
|
||||
FILE: [ResolvedTo(IMPORTS)] cyclicHierarchy2.kt
|
||||
public? final? [ResolvedTo(COMPILER_REQUIRED_ANNOTATIONS)] interface ResolveMe : A, E {
|
||||
public final? [ResolvedTo(COMPILER_REQUIRED_ANNOTATIONS)] interface ResolveMe : A, E {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface C : ResolveMe {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface C : ResolveMe {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface D : ResolveMe {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface D : ResolveMe {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface E : F {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface E : F {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface F : D, C {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface F : D, C {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
}
|
||||
|
||||
COMPANION_GENERATION:
|
||||
FILE: [ResolvedTo(IMPORTS)] cyclicHierarchy2.kt
|
||||
public? final? [ResolvedTo(COMPANION_GENERATION)] interface ResolveMe : A, E {
|
||||
public final? [ResolvedTo(COMPANION_GENERATION)] interface ResolveMe : A, E {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface C : ResolveMe {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface C : ResolveMe {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface D : ResolveMe {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface D : ResolveMe {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface E : F {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface E : F {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface F : D, C {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface F : D, C {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
}
|
||||
|
||||
SUPER_TYPES:
|
||||
FILE: [ResolvedTo(IMPORTS)] cyclicHierarchy2.kt
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface ResolveMe : <ERROR TYPE REF: Symbol not found for A>, <ERROR TYPE REF: Loop in supertype: /ResolveMe -> /E> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface ResolveMe : <ERROR TYPE REF: Symbol not found for A>, <ERROR TYPE REF: Loop in supertype: /ResolveMe -> /E> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface C : <ERROR TYPE REF: Loop in supertype: /C -> /ResolveMe> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface C : <ERROR TYPE REF: Loop in supertype: /C -> /ResolveMe> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface D : <ERROR TYPE REF: Loop in supertype: /D -> /ResolveMe> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface D : <ERROR TYPE REF: Loop in supertype: /D -> /ResolveMe> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface E : <ERROR TYPE REF: Loop in supertype: /E -> /F> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface E : <ERROR TYPE REF: Loop in supertype: /E -> /F> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface F : <ERROR TYPE REF: Loop in supertype: /F -> /D>, <ERROR TYPE REF: Loop in supertype: /F -> /C> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface F : <ERROR TYPE REF: Loop in supertype: /F -> /D>, <ERROR TYPE REF: Loop in supertype: /F -> /C> {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
}
|
||||
|
||||
TYPES:
|
||||
FILE: [ResolvedTo(IMPORTS)] cyclicHierarchy2.kt
|
||||
public? final? [ResolvedTo(TYPES)] interface ResolveMe : <ERROR TYPE REF: Symbol not found for A>, <ERROR TYPE REF: Loop in supertype: /ResolveMe -> /E> {
|
||||
public final? [ResolvedTo(TYPES)] interface ResolveMe : <ERROR TYPE REF: Symbol not found for A>, <ERROR TYPE REF: Loop in supertype: /ResolveMe -> /E> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface C : <ERROR TYPE REF: Loop in supertype: /C -> /ResolveMe> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface C : <ERROR TYPE REF: Loop in supertype: /C -> /ResolveMe> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface D : <ERROR TYPE REF: Loop in supertype: /D -> /ResolveMe> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface D : <ERROR TYPE REF: Loop in supertype: /D -> /ResolveMe> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface E : <ERROR TYPE REF: Loop in supertype: /E -> /F> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface E : <ERROR TYPE REF: Loop in supertype: /E -> /F> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface F : <ERROR TYPE REF: Loop in supertype: /F -> /D>, <ERROR TYPE REF: Loop in supertype: /F -> /C> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface F : <ERROR TYPE REF: Loop in supertype: /F -> /D>, <ERROR TYPE REF: Loop in supertype: /F -> /C> {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
}
|
||||
|
||||
STATUS:
|
||||
FILE: [ResolvedTo(IMPORTS)] cyclicHierarchy2.kt
|
||||
public abstract [ResolvedTo(STATUS)] interface ResolveMe : <ERROR TYPE REF: Symbol not found for A>, <ERROR TYPE REF: Loop in supertype: /ResolveMe -> /E> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface C : <ERROR TYPE REF: Loop in supertype: /C -> /ResolveMe> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface C : <ERROR TYPE REF: Loop in supertype: /C -> /ResolveMe> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface D : <ERROR TYPE REF: Loop in supertype: /D -> /ResolveMe> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface D : <ERROR TYPE REF: Loop in supertype: /D -> /ResolveMe> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface E : <ERROR TYPE REF: Loop in supertype: /E -> /F> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface E : <ERROR TYPE REF: Loop in supertype: /E -> /F> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface F : <ERROR TYPE REF: Loop in supertype: /F -> /D>, <ERROR TYPE REF: Loop in supertype: /F -> /C> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface F : <ERROR TYPE REF: Loop in supertype: /F -> /D>, <ERROR TYPE REF: Loop in supertype: /F -> /C> {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
}
|
||||
|
||||
EXPECT_ACTUAL_MATCHING:
|
||||
FILE: [ResolvedTo(IMPORTS)] cyclicHierarchy2.kt
|
||||
public abstract [ResolvedTo(EXPECT_ACTUAL_MATCHING)] interface ResolveMe : <ERROR TYPE REF: Symbol not found for A>, <ERROR TYPE REF: Loop in supertype: /ResolveMe -> /E> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface C : <ERROR TYPE REF: Loop in supertype: /C -> /ResolveMe> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface C : <ERROR TYPE REF: Loop in supertype: /C -> /ResolveMe> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface D : <ERROR TYPE REF: Loop in supertype: /D -> /ResolveMe> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface D : <ERROR TYPE REF: Loop in supertype: /D -> /ResolveMe> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface E : <ERROR TYPE REF: Loop in supertype: /E -> /F> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface E : <ERROR TYPE REF: Loop in supertype: /E -> /F> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface F : <ERROR TYPE REF: Loop in supertype: /F -> /D>, <ERROR TYPE REF: Loop in supertype: /F -> /C> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface F : <ERROR TYPE REF: Loop in supertype: /F -> /D>, <ERROR TYPE REF: Loop in supertype: /F -> /C> {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
}
|
||||
|
||||
CONTRACTS:
|
||||
FILE: [ResolvedTo(IMPORTS)] cyclicHierarchy2.kt
|
||||
public abstract [ResolvedTo(CONTRACTS)] interface ResolveMe : <ERROR TYPE REF: Symbol not found for A>, <ERROR TYPE REF: Loop in supertype: /ResolveMe -> /E> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface C : <ERROR TYPE REF: Loop in supertype: /C -> /ResolveMe> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface C : <ERROR TYPE REF: Loop in supertype: /C -> /ResolveMe> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface D : <ERROR TYPE REF: Loop in supertype: /D -> /ResolveMe> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface D : <ERROR TYPE REF: Loop in supertype: /D -> /ResolveMe> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface E : <ERROR TYPE REF: Loop in supertype: /E -> /F> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface E : <ERROR TYPE REF: Loop in supertype: /E -> /F> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface F : <ERROR TYPE REF: Loop in supertype: /F -> /D>, <ERROR TYPE REF: Loop in supertype: /F -> /C> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface F : <ERROR TYPE REF: Loop in supertype: /F -> /D>, <ERROR TYPE REF: Loop in supertype: /F -> /C> {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
}
|
||||
|
||||
IMPLICIT_TYPES_BODY_RESOLVE:
|
||||
FILE: [ResolvedTo(IMPORTS)] cyclicHierarchy2.kt
|
||||
public abstract [ResolvedTo(IMPLICIT_TYPES_BODY_RESOLVE)] interface ResolveMe : <ERROR TYPE REF: Symbol not found for A>, <ERROR TYPE REF: Loop in supertype: /ResolveMe -> /E> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface C : <ERROR TYPE REF: Loop in supertype: /C -> /ResolveMe> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface C : <ERROR TYPE REF: Loop in supertype: /C -> /ResolveMe> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface D : <ERROR TYPE REF: Loop in supertype: /D -> /ResolveMe> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface D : <ERROR TYPE REF: Loop in supertype: /D -> /ResolveMe> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface E : <ERROR TYPE REF: Loop in supertype: /E -> /F> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface E : <ERROR TYPE REF: Loop in supertype: /E -> /F> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface F : <ERROR TYPE REF: Loop in supertype: /F -> /D>, <ERROR TYPE REF: Loop in supertype: /F -> /C> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface F : <ERROR TYPE REF: Loop in supertype: /F -> /D>, <ERROR TYPE REF: Loop in supertype: /F -> /C> {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
}
|
||||
|
||||
ANNOTATION_ARGUMENTS:
|
||||
FILE: [ResolvedTo(IMPORTS)] cyclicHierarchy2.kt
|
||||
public abstract [ResolvedTo(ANNOTATION_ARGUMENTS)] interface ResolveMe : <ERROR TYPE REF: Symbol not found for A>, <ERROR TYPE REF: Loop in supertype: /ResolveMe -> /E> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface C : <ERROR TYPE REF: Loop in supertype: /C -> /ResolveMe> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface C : <ERROR TYPE REF: Loop in supertype: /C -> /ResolveMe> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface D : <ERROR TYPE REF: Loop in supertype: /D -> /ResolveMe> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface D : <ERROR TYPE REF: Loop in supertype: /D -> /ResolveMe> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface E : <ERROR TYPE REF: Loop in supertype: /E -> /F> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface E : <ERROR TYPE REF: Loop in supertype: /E -> /F> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface F : <ERROR TYPE REF: Loop in supertype: /F -> /D>, <ERROR TYPE REF: Loop in supertype: /F -> /C> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface F : <ERROR TYPE REF: Loop in supertype: /F -> /D>, <ERROR TYPE REF: Loop in supertype: /F -> /C> {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
}
|
||||
|
||||
BODY_RESOLVE:
|
||||
FILE: [ResolvedTo(IMPORTS)] cyclicHierarchy2.kt
|
||||
public abstract [ResolvedTo(BODY_RESOLVE)] interface ResolveMe : <ERROR TYPE REF: Symbol not found for A>, <ERROR TYPE REF: Loop in supertype: /ResolveMe -> /E> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface C : <ERROR TYPE REF: Loop in supertype: /C -> /ResolveMe> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface C : <ERROR TYPE REF: Loop in supertype: /C -> /ResolveMe> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface D : <ERROR TYPE REF: Loop in supertype: /D -> /ResolveMe> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface D : <ERROR TYPE REF: Loop in supertype: /D -> /ResolveMe> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface E : <ERROR TYPE REF: Loop in supertype: /E -> /F> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface E : <ERROR TYPE REF: Loop in supertype: /E -> /F> {
|
||||
}
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] interface F : <ERROR TYPE REF: Loop in supertype: /F -> /D>, <ERROR TYPE REF: Loop in supertype: /F -> /C> {
|
||||
public final? [ResolvedTo(SUPER_TYPES)] interface F : <ERROR TYPE REF: Loop in supertype: /F -> /D>, <ERROR TYPE REF: Loop in supertype: /F -> /C> {
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
public final? [ResolvedTo(RAW_FIR)] interface NonLoopedInterface : C {
|
||||
}
|
||||
|
||||
FILE RAW TO BODY:
|
||||
|
||||
Reference in New Issue
Block a user