[FIR] FirTypeResolveTransformer: support lazy type annotations for all declarations
^KTIJ-23547 ^KTIJ-24141
This commit is contained in:
committed by
Space Team
parent
73cdaf5c3c
commit
7f24a38997
+2
@@ -0,0 +1,2 @@
|
||||
@Anno1
|
||||
var field: @Anno1 kotlin.String!
|
||||
analysis/analysis-api/testData/symbols/symbolByReference/javaFieldWithTypeAnnotation.descriptors.txt
Vendored
+24
@@ -0,0 +1,24 @@
|
||||
KtJavaFieldSymbol:
|
||||
annotationsList: [
|
||||
Anno1()
|
||||
psi: null
|
||||
]
|
||||
callableIdIfNonLocal: /JavaClass.field
|
||||
contextReceivers: []
|
||||
isExtension: false
|
||||
isStatic: false
|
||||
isVal: false
|
||||
modality: FINAL
|
||||
name: field
|
||||
origin: JAVA
|
||||
receiverParameter: null
|
||||
returnType: [
|
||||
Anno1()
|
||||
psi: null
|
||||
] @R|Anno1|() @R|Anno1|() kotlin/String!
|
||||
symbolKind: CLASS_MEMBER
|
||||
typeParameters: []
|
||||
visibility: Public
|
||||
getDispatchReceiver(): JavaClass
|
||||
getContainingModule: KtSourceModule "Sources of main"
|
||||
deprecationStatus: null
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
// DO_NOT_CHECK_SYMBOL_RESTORE_K1
|
||||
// FILE: main.kt
|
||||
@Target(AnnotationTarget.TYPE)
|
||||
annotation class Anno1
|
||||
|
||||
fun some() {
|
||||
val jClass = JavaClass()
|
||||
jClass.<caret>field;
|
||||
}
|
||||
|
||||
// FILE: JavaClass.java
|
||||
public class JavaClass {
|
||||
public @Anno1 String field = 1;
|
||||
}
|
||||
Vendored
+2
@@ -0,0 +1,2 @@
|
||||
@Anno1
|
||||
open var field: kotlin.String!
|
||||
+21
@@ -0,0 +1,21 @@
|
||||
KtJavaFieldSymbol:
|
||||
annotationsList: [
|
||||
Anno1()
|
||||
psi: null
|
||||
]
|
||||
callableIdIfNonLocal: /JavaClass.field
|
||||
contextReceivers: []
|
||||
isExtension: false
|
||||
isStatic: false
|
||||
isVal: false
|
||||
modality: OPEN
|
||||
name: field
|
||||
origin: JAVA
|
||||
receiverParameter: null
|
||||
returnType: kotlin/String!
|
||||
symbolKind: CLASS_MEMBER
|
||||
typeParameters: []
|
||||
visibility: Public
|
||||
getDispatchReceiver(): JavaClass
|
||||
getContainingModule: KtSourceModule "Sources of main"
|
||||
deprecationStatus: null
|
||||
+21
@@ -0,0 +1,21 @@
|
||||
KtBackingFieldSymbol:
|
||||
annotationsList: []
|
||||
callableIdIfNonLocal: null
|
||||
contextReceivers: []
|
||||
isExtension: false
|
||||
name: field
|
||||
origin: PROPERTY_BACKING_FIELD
|
||||
owningProperty: KtKotlinPropertySymbol(/foo)
|
||||
receiverParameter: null
|
||||
returnType: [
|
||||
Anno3()
|
||||
psi: KtAnnotationEntry
|
||||
Anno2()
|
||||
psi: KtAnnotationEntry
|
||||
Anno1()
|
||||
psi: KtAnnotationEntry
|
||||
] @R|Anno3|() @R|Anno2|() @R|Anno1|() @R|Anno3|() SecondTypeAlias
|
||||
symbolKind: LOCAL
|
||||
typeParameters: []
|
||||
getContainingModule: KtSourceModule "Sources of main"
|
||||
deprecationStatus: null
|
||||
+21
@@ -0,0 +1,21 @@
|
||||
// DO_NOT_CHECK_NON_PSI_SYMBOL_RESTORE_K1
|
||||
// PRETTY_RENDERER_OPTION: FULLY_EXPANDED_TYPES
|
||||
|
||||
@Target(AnnotationTarget.TYPE)
|
||||
annotation class Anno1
|
||||
@Target(AnnotationTarget.TYPE)
|
||||
annotation class Anno2
|
||||
@Target(AnnotationTarget.TYPE)
|
||||
annotation class Anno3
|
||||
@Target(AnnotationTarget.TYPE)
|
||||
annotation class Anno3
|
||||
|
||||
interface BaseInterface
|
||||
|
||||
typealias FirstTypeAlias = @Anno1 BaseInterface
|
||||
typealias SecondTypeAlias = @Anno2 FirstTypeAlias
|
||||
|
||||
val foo: @Anno3 SecondTypeAlias = TODO()
|
||||
get() {
|
||||
return fie<caret>ld
|
||||
}
|
||||
Vendored
+1
@@ -0,0 +1 @@
|
||||
field
|
||||
+21
@@ -0,0 +1,21 @@
|
||||
KtBackingFieldSymbol:
|
||||
annotationsList: []
|
||||
callableIdIfNonLocal: null
|
||||
contextReceivers: []
|
||||
isExtension: false
|
||||
name: field
|
||||
origin: PROPERTY_BACKING_FIELD
|
||||
owningProperty: KtKotlinPropertySymbol(/foo)
|
||||
receiverParameter: null
|
||||
returnType: [
|
||||
Anno1()
|
||||
psi: KtAnnotationEntry
|
||||
Anno2()
|
||||
psi: KtAnnotationEntry
|
||||
Anno3()
|
||||
psi: KtAnnotationEntry
|
||||
] @R|Anno1|() @R|Anno2|() @R|Anno3|() BaseInterface
|
||||
symbolKind: LOCAL
|
||||
typeParameters: []
|
||||
getContainingModule: KtSourceModule "Sources of main"
|
||||
deprecationStatus: null
|
||||
Reference in New Issue
Block a user