KT-27445: Add QuickFix for DEPRECATED_JAVA_ANNOTATION compiler warning

This commit is contained in:
Matthew Runo
2018-10-17 15:06:56 -07:00
committed by Mikhail Glukhikh
parent 570c770d58
commit 374eec04d4
8 changed files with 127 additions and 0 deletions
@@ -0,0 +1,8 @@
// "Replace annotation with kotlin.annotation.Retention" "true"
// ERROR: Type mismatch: inferred type is RetentionPolicy but AnnotationRetention was expected
import java.lang.annotation.RetentionPolicy
import java.lang.annotation.Retention
@Retention<caret>(RetentionPolicy.SOURCE)
annotation class Foo
@@ -0,0 +1,8 @@
// "Replace annotation with kotlin.annotation.Retention" "true"
// ERROR: Type mismatch: inferred type is RetentionPolicy but AnnotationRetention was expected
import java.lang.annotation.RetentionPolicy
import kotlin.annotation.Retention
@Retention<caret>(RetentionPolicy.SOURCE)
annotation class Foo
@@ -0,0 +1,6 @@
// "Replace annotation with kotlin.annotation.MustBeDocumented" "true"
import java.lang.annotation.Documented
@Documented<caret>
annotation class Foo
@@ -0,0 +1,6 @@
// "Replace annotation with kotlin.annotation.MustBeDocumented" "true"
import kotlin.annotation.MustBeDocumented
@MustBeDocumented<caret>
annotation class Foo