11a3482970
#KT-38632 Fixed
23 lines
488 B
Kotlin
Vendored
23 lines
488 B
Kotlin
Vendored
// "Add annotation target" "true"
|
|
// ERROR: This annotation is not applicable to target 'expression'
|
|
|
|
package test
|
|
|
|
@Target(
|
|
AnnotationTarget.CLASS,
|
|
AnnotationTarget.LOCAL_VARIABLE,
|
|
AnnotationTarget.VALUE_PARAMETER,
|
|
AnnotationTarget.CONSTRUCTOR,
|
|
AnnotationTarget.FUNCTION,
|
|
AnnotationTarget.EXPRESSION
|
|
)
|
|
@Retention(AnnotationRetention.SOURCE)
|
|
annotation class AnnTarget
|
|
|
|
fun println(v: Int) {}
|
|
|
|
fun apply() {
|
|
var v = 0
|
|
<caret>@AnnTarget v++
|
|
println(v)
|
|
} |