Files
kotlin-fork/analysis/low-level-api-fir/testdata/lazyResolve/errors/annotationWithNamedFunctionArgument.txt
T
Dmitrii Gridin 2885df14ee [LL FIR] rewrite status phase transformer
Now we will try to avoid redundant calculation:
* Class-like declarations can be calculated without super types
* Overridden search logic not is out of lock

Unfortunately, right now it is not safe to use
StatusResolveMode.FunctionWithSpecificName and
StatusResolveMode.PropertyWithSpecificName
because lazyResolveToPhaseWithCallableMembers can lead to an incorrect
state of scope. Example:
```
open class A {
  open fun a() {}
  open fun b() {}
}
class C : A()
```
Steps:
1. Resolve constructor of C to STATUS
2. Now we want to call lazyResolveToPhaseWithCallableMembers on
C, and this call will do nothing because this class and all
its declarations (only constructor) are already in STATUS phase,
so class A won't be resolved as expected

^KT-56551
2023-05-19 12:43:45 +00:00

146 lines
6.3 KiB
Plaintext

RAW_FIR:
FILE: [ResolvedTo(RAW_FIR)] annotationWithNamedFunctionArgument.kt
[ResolvedTo(BODY_RESOLVE)] annotations container
@Anno[Unresolved](LAZY_EXPRESSION) public? final? [ResolvedTo(RAW_FIR)] class TopLevelClass : R|kotlin/Any| {
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=TopLevelClass] constructor(): R|TopLevelClass| {
LAZY_super<R|kotlin/Any|>
}
}
IMPORTS:
FILE: [ResolvedTo(IMPORTS)] annotationWithNamedFunctionArgument.kt
[ResolvedTo(BODY_RESOLVE)] annotations container
@Anno[Unresolved](LAZY_EXPRESSION) public? final? [ResolvedTo(RAW_FIR)] class TopLevelClass : R|kotlin/Any| {
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=TopLevelClass] constructor(): R|TopLevelClass| {
LAZY_super<R|kotlin/Any|>
}
}
COMPILER_REQUIRED_ANNOTATIONS:
FILE: [ResolvedTo(IMPORTS)] annotationWithNamedFunctionArgument.kt
[ResolvedTo(BODY_RESOLVE)] annotations container
@Anno[Unresolved](LAZY_EXPRESSION) public? final? [ResolvedTo(COMPILER_REQUIRED_ANNOTATIONS)] class TopLevelClass : R|kotlin/Any| {
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=TopLevelClass] constructor(): R|TopLevelClass| {
LAZY_super<R|kotlin/Any|>
}
}
COMPANION_GENERATION:
FILE: [ResolvedTo(IMPORTS)] annotationWithNamedFunctionArgument.kt
[ResolvedTo(BODY_RESOLVE)] annotations container
@Anno[Unresolved](LAZY_EXPRESSION) public? final? [ResolvedTo(COMPANION_GENERATION)] class TopLevelClass : R|kotlin/Any| {
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=TopLevelClass] constructor(): R|TopLevelClass| {
LAZY_super<R|kotlin/Any|>
}
}
SUPER_TYPES:
FILE: [ResolvedTo(IMPORTS)] annotationWithNamedFunctionArgument.kt
[ResolvedTo(BODY_RESOLVE)] annotations container
@Anno[Unresolved](LAZY_EXPRESSION) public? final? [ResolvedTo(SUPER_TYPES)] class TopLevelClass : R|kotlin/Any| {
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=TopLevelClass] constructor(): R|TopLevelClass| {
LAZY_super<R|kotlin/Any|>
}
}
TYPES:
FILE: [ResolvedTo(IMPORTS)] annotationWithNamedFunctionArgument.kt
[ResolvedTo(BODY_RESOLVE)] annotations container
@<ERROR TYPE REF: Symbol not found for Anno>[Types](LAZY_EXPRESSION) public? final? [ResolvedTo(TYPES)] class TopLevelClass : R|kotlin/Any| {
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=TopLevelClass] constructor(): R|TopLevelClass| {
LAZY_super<R|kotlin/Any|>
}
}
STATUS:
FILE: [ResolvedTo(IMPORTS)] annotationWithNamedFunctionArgument.kt
[ResolvedTo(BODY_RESOLVE)] annotations container
@<ERROR TYPE REF: Symbol not found for Anno>[Types](LAZY_EXPRESSION) public final [ResolvedTo(STATUS)] class TopLevelClass : R|kotlin/Any| {
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=TopLevelClass] constructor(): R|TopLevelClass| {
LAZY_super<R|kotlin/Any|>
}
}
EXPECT_ACTUAL_MATCHING:
FILE: [ResolvedTo(IMPORTS)] annotationWithNamedFunctionArgument.kt
[ResolvedTo(BODY_RESOLVE)] annotations container
@<ERROR TYPE REF: Symbol not found for Anno>[Types](LAZY_EXPRESSION) public final [ResolvedTo(EXPECT_ACTUAL_MATCHING)] class TopLevelClass : R|kotlin/Any| {
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=TopLevelClass] constructor(): R|TopLevelClass| {
LAZY_super<R|kotlin/Any|>
}
}
ARGUMENTS_OF_ANNOTATIONS:
FILE: [ResolvedTo(IMPORTS)] annotationWithNamedFunctionArgument.kt
[ResolvedTo(BODY_RESOLVE)] annotations container
@<ERROR TYPE REF: Symbol not found for Anno>[Types](ERROR_EXPR(Incorrect invoke receiver)local final? [ResolvedTo(RAW_FIR)] fun a(): String {
}
.invoke#()) public final [ResolvedTo(ARGUMENTS_OF_ANNOTATIONS)] class TopLevelClass : R|kotlin/Any| {
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=TopLevelClass] constructor(): R|TopLevelClass| {
LAZY_super<R|kotlin/Any|>
}
}
CONTRACTS:
FILE: [ResolvedTo(IMPORTS)] annotationWithNamedFunctionArgument.kt
[ResolvedTo(BODY_RESOLVE)] annotations container
@<ERROR TYPE REF: Symbol not found for Anno>[Types](ERROR_EXPR(Incorrect invoke receiver)local final? [ResolvedTo(RAW_FIR)] fun a(): String {
}
.invoke#()) public final [ResolvedTo(CONTRACTS)] class TopLevelClass : R|kotlin/Any| {
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=TopLevelClass] constructor(): R|TopLevelClass| {
LAZY_super<R|kotlin/Any|>
}
}
IMPLICIT_TYPES_BODY_RESOLVE:
FILE: [ResolvedTo(IMPORTS)] annotationWithNamedFunctionArgument.kt
[ResolvedTo(BODY_RESOLVE)] annotations container
@<ERROR TYPE REF: Symbol not found for Anno>[Types](ERROR_EXPR(Incorrect invoke receiver)local final? [ResolvedTo(RAW_FIR)] fun a(): String {
}
.invoke#()) public final [ResolvedTo(IMPLICIT_TYPES_BODY_RESOLVE)] class TopLevelClass : R|kotlin/Any| {
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=TopLevelClass] constructor(): R|TopLevelClass| {
LAZY_super<R|kotlin/Any|>
}
}
ANNOTATIONS_ARGUMENTS_MAPPING:
FILE: [ResolvedTo(IMPORTS)] annotationWithNamedFunctionArgument.kt
[ResolvedTo(BODY_RESOLVE)] annotations container
@<ERROR TYPE REF: Symbol not found for Anno>[Types]() public final [ResolvedTo(ANNOTATIONS_ARGUMENTS_MAPPING)] class TopLevelClass : R|kotlin/Any| {
public? [ResolvedTo(RAW_FIR)] [ContainingClassKey=TopLevelClass] constructor(): R|TopLevelClass| {
LAZY_super<R|kotlin/Any|>
}
}
BODY_RESOLVE:
FILE: [ResolvedTo(IMPORTS)] annotationWithNamedFunctionArgument.kt
[ResolvedTo(BODY_RESOLVE)] annotations container
@<ERROR TYPE REF: Symbol not found for Anno>[Types]() public final [ResolvedTo(BODY_RESOLVE)] class TopLevelClass : R|kotlin/Any| {
public [ResolvedTo(BODY_RESOLVE)] [ContainingClassKey=TopLevelClass] constructor(): R|TopLevelClass| {
super<R|kotlin/Any|>()
}
}
FILE RAW TO BODY:
FILE: [ResolvedTo(IMPORTS)] annotationWithNamedFunctionArgument.kt
[ResolvedTo(BODY_RESOLVE)] annotations container
@<ERROR TYPE REF: Symbol not found for Anno>[Types]() public final [ResolvedTo(BODY_RESOLVE)] class TopLevelClass : R|kotlin/Any| {
public [ResolvedTo(BODY_RESOLVE)] [ContainingClassKey=TopLevelClass] constructor(): R|TopLevelClass| {
super<R|kotlin/Any|>()
}
}