[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
@@ -2,7 +2,7 @@ RAW_FIR:
|
||||
FILE: [ResolvedTo(RAW_FIR)] secondaryConstructor.kt
|
||||
public? final? [ResolvedTo(RAW_FIR)] fun resolveMe(): R|kotlin/Unit| { LAZY_BLOCK }
|
||||
public? final? [ResolvedTo(RAW_FIR)] fun receive([ResolvedTo(RAW_FIR)] value: A): R|kotlin/Unit| { LAZY_BLOCK }
|
||||
public? final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=A] constructor([ResolvedTo(RAW_FIR)] x: Int): R|A| { LAZY_BLOCK }
|
||||
|
||||
}
|
||||
@@ -11,7 +11,7 @@ IMPORTS:
|
||||
FILE: [ResolvedTo(IMPORTS)] secondaryConstructor.kt
|
||||
public? final? [ResolvedTo(RAW_FIR)] fun resolveMe(): R|kotlin/Unit| { LAZY_BLOCK }
|
||||
public? final? [ResolvedTo(RAW_FIR)] fun receive([ResolvedTo(RAW_FIR)] value: A): R|kotlin/Unit| { LAZY_BLOCK }
|
||||
public? final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=A] constructor([ResolvedTo(RAW_FIR)] x: Int): R|A| { LAZY_BLOCK }
|
||||
|
||||
}
|
||||
@@ -20,7 +20,7 @@ COMPILER_REQUIRED_ANNOTATIONS:
|
||||
FILE: [ResolvedTo(IMPORTS)] secondaryConstructor.kt
|
||||
public? final? [ResolvedTo(COMPILER_REQUIRED_ANNOTATIONS)] fun resolveMe(): R|kotlin/Unit| { LAZY_BLOCK }
|
||||
public? final? [ResolvedTo(RAW_FIR)] fun receive([ResolvedTo(RAW_FIR)] value: A): R|kotlin/Unit| { LAZY_BLOCK }
|
||||
public? final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=A] constructor([ResolvedTo(RAW_FIR)] x: Int): R|A| { LAZY_BLOCK }
|
||||
|
||||
}
|
||||
@@ -29,7 +29,7 @@ COMPANION_GENERATION:
|
||||
FILE: [ResolvedTo(IMPORTS)] secondaryConstructor.kt
|
||||
public? final? [ResolvedTo(COMPANION_GENERATION)] fun resolveMe(): R|kotlin/Unit| { LAZY_BLOCK }
|
||||
public? final? [ResolvedTo(RAW_FIR)] fun receive([ResolvedTo(RAW_FIR)] value: A): R|kotlin/Unit| { LAZY_BLOCK }
|
||||
public? final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=A] constructor([ResolvedTo(RAW_FIR)] x: Int): R|A| { LAZY_BLOCK }
|
||||
|
||||
}
|
||||
@@ -38,7 +38,7 @@ SUPER_TYPES:
|
||||
FILE: [ResolvedTo(IMPORTS)] secondaryConstructor.kt
|
||||
public? final? [ResolvedTo(SUPER_TYPES)] fun resolveMe(): R|kotlin/Unit| { LAZY_BLOCK }
|
||||
public? final? [ResolvedTo(RAW_FIR)] fun receive([ResolvedTo(RAW_FIR)] value: A): R|kotlin/Unit| { LAZY_BLOCK }
|
||||
public? final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=A] constructor([ResolvedTo(RAW_FIR)] x: Int): R|A| { LAZY_BLOCK }
|
||||
|
||||
}
|
||||
@@ -47,7 +47,7 @@ TYPES:
|
||||
FILE: [ResolvedTo(IMPORTS)] secondaryConstructor.kt
|
||||
public? final? [ResolvedTo(TYPES)] fun resolveMe(): R|kotlin/Unit| { LAZY_BLOCK }
|
||||
public? final? [ResolvedTo(RAW_FIR)] fun receive([ResolvedTo(RAW_FIR)] value: A): R|kotlin/Unit| { LAZY_BLOCK }
|
||||
public? final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=A] constructor([ResolvedTo(RAW_FIR)] x: Int): R|A| { LAZY_BLOCK }
|
||||
|
||||
}
|
||||
@@ -56,7 +56,7 @@ STATUS:
|
||||
FILE: [ResolvedTo(IMPORTS)] secondaryConstructor.kt
|
||||
public final [ResolvedTo(STATUS)] fun resolveMe(): R|kotlin/Unit| { LAZY_BLOCK }
|
||||
public? final? [ResolvedTo(RAW_FIR)] fun receive([ResolvedTo(RAW_FIR)] value: A): R|kotlin/Unit| { LAZY_BLOCK }
|
||||
public? final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=A] constructor([ResolvedTo(RAW_FIR)] x: Int): R|A| { LAZY_BLOCK }
|
||||
|
||||
}
|
||||
@@ -65,7 +65,7 @@ EXPECT_ACTUAL_MATCHING:
|
||||
FILE: [ResolvedTo(IMPORTS)] secondaryConstructor.kt
|
||||
public final [ResolvedTo(EXPECT_ACTUAL_MATCHING)] fun resolveMe(): R|kotlin/Unit| { LAZY_BLOCK }
|
||||
public? final? [ResolvedTo(RAW_FIR)] fun receive([ResolvedTo(RAW_FIR)] value: A): R|kotlin/Unit| { LAZY_BLOCK }
|
||||
public? final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=A] constructor([ResolvedTo(RAW_FIR)] x: Int): R|A| { LAZY_BLOCK }
|
||||
|
||||
}
|
||||
@@ -76,7 +76,7 @@ FILE: [ResolvedTo(IMPORTS)] secondaryConstructor.kt
|
||||
receive#(A#(IntegerLiteral(42)))
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] fun receive([ResolvedTo(RAW_FIR)] value: A): R|kotlin/Unit| { LAZY_BLOCK }
|
||||
public? final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=A] constructor([ResolvedTo(RAW_FIR)] x: Int): R|A| { LAZY_BLOCK }
|
||||
|
||||
}
|
||||
@@ -87,7 +87,7 @@ FILE: [ResolvedTo(IMPORTS)] secondaryConstructor.kt
|
||||
receive#(A#(IntegerLiteral(42)))
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] fun receive([ResolvedTo(RAW_FIR)] value: A): R|kotlin/Unit| { LAZY_BLOCK }
|
||||
public? final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=A] constructor([ResolvedTo(RAW_FIR)] x: Int): R|A| { LAZY_BLOCK }
|
||||
|
||||
}
|
||||
@@ -98,7 +98,7 @@ FILE: [ResolvedTo(IMPORTS)] secondaryConstructor.kt
|
||||
receive#(A#(IntegerLiteral(42)))
|
||||
}
|
||||
public? final? [ResolvedTo(RAW_FIR)] fun receive([ResolvedTo(RAW_FIR)] value: A): R|kotlin/Unit| { LAZY_BLOCK }
|
||||
public? final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public final? [ResolvedTo(RAW_FIR)] class A : R|kotlin/Any| {
|
||||
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=A] constructor([ResolvedTo(RAW_FIR)] x: Int): R|A| { LAZY_BLOCK }
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user