K2: report PRE_RELEASE_CLASS on JVM

Note that 3 tests are still muted, but for another reason: for FIR
versions of the tests, we need to compile the "pre-release library" with
the next language version which is 2.1. But since currently
LanguageVersion.LATEST_STABLE is 1.9, the compiler refuses to read
metadata of version 2.1, regardless of its own language version. Which
is correct, but it leads to irrelevant errors in the test output -- the
ones about the incompatible metadata version, NOT about the
prereleaseness.

These 3 tests can be unmuted once the default language version is
switched to 2.0.

 #KT-60780 Fixed
This commit is contained in:
Alexander Udalov
2023-08-12 00:06:48 +02:00
committed by Space Team
parent 8738ffb84f
commit fec2d063c1
14 changed files with 96 additions and 10 deletions
@@ -28,7 +28,7 @@ object FirDiagnosticsCompilerResultsReporter {
}.also {
AnalyzerWithCompilerReport.reportSpecialErrors(
diagnosticsCollector.diagnostics.any { it.factory == FirJvmErrors.INCOMPATIBLE_CLASS },
hasPrereleaseClasses = false, // TODO (KT-60780): missing PRE_RELEASE_CLASS
diagnosticsCollector.diagnostics.any { it.factory == FirJvmErrors.PRE_RELEASE_CLASS },
hasUnstableClasses = false, // TODO (KT-61598): report FIR_COMPILED_CLASS and IR_WITH_UNSTABLE_ABI_COMPILED_CLASS
hasFirUnstableClasses = false, // TODO (KT-61598): report FIR_COMPILED_CLASS and IR_WITH_UNSTABLE_ABI_COMPILED_CLASS
messageCollector,