[FIR] Fix WRONG_ANNOTATION_TARGET for annotation for block, ^KT-52175 Fixed

This commit is contained in:
Ivan Kochurkin
2022-05-31 22:32:15 +03:00
committed by teamcity
parent b573532d8c
commit 34b5ce21a1
8 changed files with 75 additions and 1 deletions
@@ -0,0 +1,28 @@
FILE: AnnotatedBlock.kt
public final annotation class Ann : R|kotlin/Annotation| {
public constructor(): R|Ann| {
super<R|kotlin/Any|>()
}
}
public final annotation class Ann2 : R|kotlin/Annotation| {
public constructor(): R|Ann2| {
super<R|kotlin/Any|>()
}
}
public final fun test(x: R|kotlin/String?|): R|kotlin/Unit| {
when () {
!=(R|<local>/x|, Null(null)) -> @R|Ann|() @R|Ann2|() {
Q|kotlin/Unit|
}
}
when () {
!=(R|<local>/x|, Null(null)) -> {
@R|Ann|() @R|Ann2|() Q|kotlin/Unit|
}
}
@R|Ann|() @R|Ann2|() R|<local>/x|
}