[LL FIR] make script initializers independent

Now we can resolve all script declarations independently

^KT-65344 Fixed
This commit is contained in:
Dmitrii Gridin
2024-02-05 15:57:24 +01:00
committed by Space Team
parent d59b8b3244
commit 58ad26ee5b
26 changed files with 535 additions and 362 deletions
@@ -8,20 +8,16 @@ R|/bar|()
FIR FILE:
FILE: [ResolvedTo(IMPORTS)] secondStatementCall.kts
context(<script>@R|kotlin/script/templates/standard/ScriptTemplateWithArgs|)
SCRIPT: [ResolvedTo(BODY_RESOLVE)] <script-secondStatementCall.kts>
[ResolvedTo(BODY_RESOLVE)] lval args: R|kotlin/Array<kotlin/String>|
SCRIPT: [ResolvedTo(TYPES)] <script-secondStatementCall.kts>
[ResolvedTo(RAW_FIR)] lval args: R|kotlin/Array<kotlin/String>|
public final [ResolvedTo(IMPLICIT_TYPES_BODY_RESOLVE)] fun foo(): R|kotlin/Int| {
^foo Int(4)
}
public? final? [ResolvedTo(RAW_FIR)] fun foo(): <implicit> { LAZY_BLOCK }
[ResolvedTo(BODY_RESOLVE)] init {
R|/foo|()
}
[ResolvedTo(RAW_FIR)] init { LAZY_BLOCK }
[ResolvedTo(BODY_RESOLVE)] init {
R|/bar|()
}
public final [ResolvedTo(CONTRACTS)] fun bar(): R|kotlin/Unit| {
}
}