[FIR] Add INAPPLICABLE_JVM_FIELD, INAPPLICABLE_JVM_FIELD_WARNING
This commit is contained in:
committed by
TeamCityServer
parent
e3805c9b98
commit
3725c58794
+14
@@ -3780,4 +3780,18 @@ internal val KT_DIAGNOSTIC_CONVERTER = KtDiagnosticConverterBuilder.buildConvert
|
||||
token,
|
||||
)
|
||||
}
|
||||
add(FirJvmErrors.INAPPLICABLE_JVM_FIELD) { firDiagnostic ->
|
||||
InapplicableJvmFieldImpl(
|
||||
firDiagnostic.a,
|
||||
firDiagnostic as FirPsiDiagnostic,
|
||||
token,
|
||||
)
|
||||
}
|
||||
add(FirJvmErrors.INAPPLICABLE_JVM_FIELD_WARNING) { firDiagnostic ->
|
||||
InapplicableJvmFieldWarningImpl(
|
||||
firDiagnostic.a,
|
||||
firDiagnostic as FirPsiDiagnostic,
|
||||
token,
|
||||
)
|
||||
}
|
||||
}
|
||||
|
||||
+10
@@ -2628,4 +2628,14 @@ sealed class KtFirDiagnostic<PSI : PsiElement> : KtDiagnosticWithPsi<PSI> {
|
||||
override val diagnosticClass get() = ExternalDeclarationCannotBeInlined::class
|
||||
}
|
||||
|
||||
abstract class InapplicableJvmField : KtFirDiagnostic<KtAnnotationEntry>() {
|
||||
override val diagnosticClass get() = InapplicableJvmField::class
|
||||
abstract val message: String
|
||||
}
|
||||
|
||||
abstract class InapplicableJvmFieldWarning : KtFirDiagnostic<KtAnnotationEntry>() {
|
||||
override val diagnosticClass get() = InapplicableJvmFieldWarning::class
|
||||
abstract val message: String
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
+16
@@ -4273,3 +4273,19 @@ internal class ExternalDeclarationCannotBeInlinedImpl(
|
||||
override val firDiagnostic: FirPsiDiagnostic by weakRef(firDiagnostic)
|
||||
}
|
||||
|
||||
internal class InapplicableJvmFieldImpl(
|
||||
override val message: String,
|
||||
firDiagnostic: FirPsiDiagnostic,
|
||||
override val token: ValidityToken,
|
||||
) : KtFirDiagnostic.InapplicableJvmField(), KtAbstractFirDiagnostic<KtAnnotationEntry> {
|
||||
override val firDiagnostic: FirPsiDiagnostic by weakRef(firDiagnostic)
|
||||
}
|
||||
|
||||
internal class InapplicableJvmFieldWarningImpl(
|
||||
override val message: String,
|
||||
firDiagnostic: FirPsiDiagnostic,
|
||||
override val token: ValidityToken,
|
||||
) : KtFirDiagnostic.InapplicableJvmFieldWarning(), KtAbstractFirDiagnostic<KtAnnotationEntry> {
|
||||
override val firDiagnostic: FirPsiDiagnostic by weakRef(firDiagnostic)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user