[FIR] Fix ambiguity of Throws and other std annotations importing

Including `SharedImmutable` and `ThreadLocal`

Simplify code, remove `DefaultImportPriority.KOTLIN_THROWS`

Introduce `FirNativeClassMapper`
This commit is contained in:
Ivan Kochurkin
2023-11-14 17:22:13 +01:00
committed by Space Team
parent adf4f823ae
commit 115d685d91
151 changed files with 656 additions and 931 deletions
@@ -0,0 +1,11 @@
import kotlin.*
import kotlin.jvm.*
import kotlin.native.concurrent.*
import kotlin.native.*
@<!DEPRECATION!>SharedImmutable<!>
@ThreadLocal
val x = 42
@Throws(Exception::class)
fun test() {}
@@ -0,0 +1,11 @@
import kotlin.*
import kotlin.jvm.*
import kotlin.native.concurrent.*
import kotlin.native.*
@<!DEPRECATION, TYPEALIAS_EXPANSION_DEPRECATION!>SharedImmutable<!>
@<!DEPRECATION!>ThreadLocal<!>
val x = 42
@Throws(Exception::class)
fun test() {}
@@ -72,7 +72,7 @@ package abc4
import kotlin.<!CONFLICTING_IMPORT!>Throws<!>
import <!DEPRECATION!>kotlin.native.<!CONFLICTING_IMPORT!>Throws<!><!>
@<!OVERLOAD_RESOLUTION_AMBIGUITY!>Throws<!>(Throwable::class)
@Throws(Throwable::class)
fun foo1() {}
@kotlin.Throws(Throwable::class)
@@ -81,7 +81,7 @@ fun foo2() {}
@<!DEPRECATION!>kotlin.native.Throws<!>(Throwable::class)
fun foo3() {}
fun foo5(x: <!OVERLOAD_RESOLUTION_AMBIGUITY!>Throws<!>) {}
fun foo5(x: Throws) {}
fun foo6(x: kotlin.Throws) {}
fun foo7(x: <!DEPRECATION!>kotlin.native.Throws<!>) {}
@@ -127,7 +127,7 @@ package abc7
import kotlin.*
import kotlin.native.*
@<!OVERLOAD_RESOLUTION_AMBIGUITY!>Throws<!>(Throwable::class)
@Throws(Throwable::class)
fun foo1() {}
@kotlin.Throws(Throwable::class)
@@ -136,7 +136,7 @@ fun foo2() {}
@<!DEPRECATION!>kotlin.native.Throws<!>(Throwable::class)
fun foo3() {}
fun foo5(x: <!OVERLOAD_RESOLUTION_AMBIGUITY!>Throws<!>) {}
fun foo5(x: Throws) {}
fun foo6(x: kotlin.Throws) {}
fun foo7(x: <!DEPRECATION!>kotlin.native.Throws<!>) {}