[FIR] Fix enhancement of FlexibleNullability and EnhancedNullability

- Add utilities to add new attribute to ConeAttributes
- Get rid of FlexibleNullability attribute (it can be easily inferred
    for any flexible type at any moment)
- Fix determining of EnhancedNullability attribute
This commit is contained in:
Dmitriy Novozhilov
2021-03-09 14:51:19 +03:00
parent 0108f8a1b4
commit 65ea4e184a
290 changed files with 1395 additions and 2037 deletions
@@ -1,10 +1,10 @@
FILE: main.kt
public final fun test_1(x: R|A|): R|kotlin/Unit| {
lval str1: R|ft<@FlexibleNullability kotlin/String, kotlin/String?>!| = R|<local>/x|.R|/A.vmParameters|
lval str1: R|ft<kotlin/String, kotlin/String?>!| = R|<local>/x|.R|/A.vmParameters|
lval str2: R|ERROR CLASS: Unresolved name: vMParameters| = R|<local>/x|.<Unresolved name: vMParameters>#
}
public final fun test_2(x: R|B|): R|kotlin/Unit| {
lval int: R|ft<@FlexibleNullability kotlin/Int, kotlin/Int?>!| = R|<local>/x|.R|/B.vmParameters|
lval int: R|ft<kotlin/Int, kotlin/Int?>!| = R|<local>/x|.R|/B.vmParameters|
lval error: R|ERROR CLASS: Unresolved name: vMParameters| = R|<local>/x|.<Unresolved name: vMParameters>#
}
public final fun test_3(x: R|C|): R|kotlin/Unit| {