Parse some builtin annotations as modifiers
But still resolve them as annotations. Mostly it's needed as begin of migration path, one day they become modifiers anyway Some tests are dropped because they supposed that `annotation` should have parameter
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
interface T
|
||||
class T1(<warning>t</warning>: Int): T
|
||||
|
||||
inline fun <T> run(f: () -> T) = f()
|
||||
<info descr="null">inline</info> fun <T> run(f: () -> T) = f()
|
||||
|
||||
|
||||
class Delegate(<warning>d</warning>: Int) {
|
||||
|
||||
+2
-2
@@ -1,4 +1,4 @@
|
||||
inline fun <T> run(f: () -> T) = f()
|
||||
<info descr="null">inline</info> fun <T> run(f: () -> T) = f()
|
||||
fun run2(f: () -> Unit) = f()
|
||||
|
||||
fun inline() {
|
||||
@@ -90,7 +90,7 @@ fun objectExpression() {
|
||||
}
|
||||
}
|
||||
|
||||
inline fun withNoInlineParam(noinline task1: () -> Unit, task2: () -> Unit) {
|
||||
<info>inline</info> fun withNoInlineParam(<info>noinline</info> task1: () -> Unit, task2: () -> Unit) {
|
||||
task1()
|
||||
task2()
|
||||
}
|
||||
|
||||
@@ -3,8 +3,8 @@
|
||||
|
||||
package test
|
||||
|
||||
kotlin.data dependency.A dependency.B dependency.C public final class Annotations public constructor() {
|
||||
kotlin.inline dependency.A dependency.B dependency.C public final val p: @[dependency.B] kotlin.Int /* compiled code */
|
||||
dependency.A dependency.B dependency.C kotlin.data public final class Annotations public constructor() {
|
||||
dependency.A dependency.B dependency.C kotlin.inline public final val p: @[dependency.B] kotlin.Int /* compiled code */
|
||||
|
||||
kotlin.inline dependency.A dependency.B dependency.C public final fun f(dependency.A dependency.B dependency.C kotlin.Deprecated i: @[dependency.A] kotlin.Int): kotlin.Unit { /* compiled code */ }
|
||||
dependency.A dependency.B dependency.C kotlin.inline public final fun f(dependency.A dependency.B dependency.C kotlin.Deprecated i: @[dependency.A] kotlin.Int): kotlin.Unit { /* compiled code */ }
|
||||
}
|
||||
+2
-2
@@ -4,8 +4,8 @@ interface <info textAttributesKey="KOTLIN_TRAIT">TheTrait</info> {
|
||||
class <info textAttributesKey="KOTLIN_CLASS">TheClass</info> : <info textAttributesKey="KOTLIN_TRAIT">TheTrait</info> {
|
||||
}
|
||||
|
||||
<info textAttributesKey="KOTLIN_ANNOTATION">annotation</info> class <info textAttributesKey="KOTLIN_ANNOTATION">magnificent</info>
|
||||
<info textAttributesKey="KOTLIN_ANNOTATION">annotation</info> class <info textAttributesKey="KOTLIN_ANNOTATION">Deprecated</info>
|
||||
<info textAttributesKey="KOTLIN_BUILTIN_ANNOTATION">annotation</info> class <info textAttributesKey="KOTLIN_ANNOTATION">magnificent</info>
|
||||
<info textAttributesKey="KOTLIN_BUILTIN_ANNOTATION">annotation</info> class <info textAttributesKey="KOTLIN_ANNOTATION">Deprecated</info>
|
||||
|
||||
<info textAttributesKey="KOTLIN_ANNOTATION">@Deprecated</info>
|
||||
<info textAttributesKey="KOTLIN_ANNOTATION">magnificent</info> <info textAttributesKey="KOTLIN_BUILTIN_ANNOTATION">abstract</info> class <info textAttributesKey="KOTLIN_ABSTRACT_CLASS">AbstractClass</info><<info textAttributesKey="KOTLIN_TYPE_PARAMETER">T</info>> {
|
||||
|
||||
+1
-6
@@ -2,9 +2,4 @@ PsiJetFileStubImpl[package=]
|
||||
PACKAGE_DIRECTIVE:
|
||||
IMPORT_LIST:
|
||||
CLASS:[fqName=Test, isEnumEntry=false, isInterface=false, isLocal=false, isTopLevel=true, name=Test, superNames=[]]
|
||||
MODIFIER_LIST:[]
|
||||
ANNOTATION_ENTRY:[hasValueArguments=false, shortName=annotation]
|
||||
CONSTRUCTOR_CALLEE:
|
||||
TYPE_REFERENCE:
|
||||
USER_TYPE:[isAbsoluteInRootPackage=false]
|
||||
REFERENCE_EXPRESSION:[referencedName=annotation]
|
||||
MODIFIER_LIST:[annotation]
|
||||
|
||||
+1
-6
@@ -77,9 +77,4 @@ PsiJetFileStubImpl[package=test]
|
||||
MODIFIER_LIST:[internal]
|
||||
VALUE_PARAMETER_LIST:
|
||||
CLASS:[fqName=test.anno, isEnumEntry=false, isInterface=false, isLocal=false, isTopLevel=true, name=anno, superNames=[]]
|
||||
MODIFIER_LIST:[]
|
||||
ANNOTATION_ENTRY:[hasValueArguments=false, shortName=annotation]
|
||||
CONSTRUCTOR_CALLEE:
|
||||
TYPE_REFERENCE:
|
||||
USER_TYPE:[isAbsoluteInRootPackage=false]
|
||||
REFERENCE_EXPRESSION:[referencedName=annotation]
|
||||
MODIFIER_LIST:[annotation]
|
||||
|
||||
+2
-12
@@ -2,19 +2,9 @@ PsiJetFileStubImpl[package=]
|
||||
PACKAGE_DIRECTIVE:
|
||||
IMPORT_LIST:
|
||||
CLASS:[fqName=a, isEnumEntry=false, isInterface=false, isLocal=false, isTopLevel=true, name=a, superNames=[]]
|
||||
MODIFIER_LIST:[]
|
||||
ANNOTATION_ENTRY:[hasValueArguments=false, shortName=annotation]
|
||||
CONSTRUCTOR_CALLEE:
|
||||
TYPE_REFERENCE:
|
||||
USER_TYPE:[isAbsoluteInRootPackage=false]
|
||||
REFERENCE_EXPRESSION:[referencedName=annotation]
|
||||
MODIFIER_LIST:[annotation]
|
||||
CLASS:[fqName=b, isEnumEntry=false, isInterface=false, isLocal=false, isTopLevel=true, name=b, superNames=[]]
|
||||
MODIFIER_LIST:[]
|
||||
ANNOTATION_ENTRY:[hasValueArguments=false, shortName=annotation]
|
||||
CONSTRUCTOR_CALLEE:
|
||||
TYPE_REFERENCE:
|
||||
USER_TYPE:[isAbsoluteInRootPackage=false]
|
||||
REFERENCE_EXPRESSION:[referencedName=annotation]
|
||||
MODIFIER_LIST:[annotation]
|
||||
PRIMARY_CONSTRUCTOR:
|
||||
VALUE_PARAMETER_LIST:
|
||||
VALUE_PARAMETER:[fqName=b.e, hasDefaultValue=false, hasValOrVar=true, isMutable=false, name=e]
|
||||
|
||||
Reference in New Issue
Block a user