RAW_FIR:
FILE: [ResolvedTo(IMPORTS)] functionCallWithGenericResultScript.kts
    context(<script>@R|kotlin/script/templates/standard/ScriptTemplateWithArgs|)
    SCRIPT: [ResolvedTo(BODY_RESOLVE)] 
        [ResolvedTo(RAW_FIR)] lval args: R|kotlin/Array<kotlin/String>|

        public open [ResolvedTo(STATUS)] class Foo<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|> : R|kotlin/Any| {
            public [ResolvedTo(STATUS)] [ContainingClassKey=Foo] constructor<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|>(): R|Foo<T>| {
                super<R|kotlin/Any|>()
            }

        }

        public final [ResolvedTo(RAW_FIR)] fun bar(): R|Foo<kotlin/String>?| {
            ^bar Null(null)
        }

        public final [ResolvedTo(RAW_FIR)] fun resolveMe(): R|kotlin/Unit| {
            [ResolvedTo(RAW_FIR)] lval x: R|Foo<kotlin/String>?| = R|/bar|()
        }


IMPORTS:
FILE: [ResolvedTo(IMPORTS)] functionCallWithGenericResultScript.kts
    context(<script>@R|kotlin/script/templates/standard/ScriptTemplateWithArgs|)
    SCRIPT: [ResolvedTo(BODY_RESOLVE)] 
        [ResolvedTo(RAW_FIR)] lval args: R|kotlin/Array<kotlin/String>|

        public open [ResolvedTo(STATUS)] class Foo<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|> : R|kotlin/Any| {
            public [ResolvedTo(STATUS)] [ContainingClassKey=Foo] constructor<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|>(): R|Foo<T>| {
                super<R|kotlin/Any|>()
            }

        }

        public final [ResolvedTo(RAW_FIR)] fun bar(): R|Foo<kotlin/String>?| {
            ^bar Null(null)
        }

        public final [ResolvedTo(RAW_FIR)] fun resolveMe(): R|kotlin/Unit| {
            [ResolvedTo(RAW_FIR)] lval x: R|Foo<kotlin/String>?| = R|/bar|()
        }


COMPILER_REQUIRED_ANNOTATIONS:
FILE: [ResolvedTo(IMPORTS)] functionCallWithGenericResultScript.kts
    context(<script>@R|kotlin/script/templates/standard/ScriptTemplateWithArgs|)
    SCRIPT: [ResolvedTo(BODY_RESOLVE)] 
        [ResolvedTo(RAW_FIR)] lval args: R|kotlin/Array<kotlin/String>|

        public open [ResolvedTo(STATUS)] class Foo<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|> : R|kotlin/Any| {
            public [ResolvedTo(STATUS)] [ContainingClassKey=Foo] constructor<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|>(): R|Foo<T>| {
                super<R|kotlin/Any|>()
            }

        }

        public final [ResolvedTo(RAW_FIR)] fun bar(): R|Foo<kotlin/String>?| {
            ^bar Null(null)
        }

        public final [ResolvedTo(RAW_FIR)] fun resolveMe(): R|kotlin/Unit| {
            [ResolvedTo(RAW_FIR)] lval x: R|Foo<kotlin/String>?| = R|/bar|()
        }


COMPANION_GENERATION:
FILE: [ResolvedTo(IMPORTS)] functionCallWithGenericResultScript.kts
    context(<script>@R|kotlin/script/templates/standard/ScriptTemplateWithArgs|)
    SCRIPT: [ResolvedTo(BODY_RESOLVE)] 
        [ResolvedTo(RAW_FIR)] lval args: R|kotlin/Array<kotlin/String>|

        public open [ResolvedTo(STATUS)] class Foo<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|> : R|kotlin/Any| {
            public [ResolvedTo(STATUS)] [ContainingClassKey=Foo] constructor<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|>(): R|Foo<T>| {
                super<R|kotlin/Any|>()
            }

        }

        public final [ResolvedTo(RAW_FIR)] fun bar(): R|Foo<kotlin/String>?| {
            ^bar Null(null)
        }

        public final [ResolvedTo(RAW_FIR)] fun resolveMe(): R|kotlin/Unit| {
            [ResolvedTo(RAW_FIR)] lval x: R|Foo<kotlin/String>?| = R|/bar|()
        }


SUPER_TYPES:
FILE: [ResolvedTo(IMPORTS)] functionCallWithGenericResultScript.kts
    context(<script>@R|kotlin/script/templates/standard/ScriptTemplateWithArgs|)
    SCRIPT: [ResolvedTo(BODY_RESOLVE)] 
        [ResolvedTo(RAW_FIR)] lval args: R|kotlin/Array<kotlin/String>|

        public open [ResolvedTo(STATUS)] class Foo<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|> : R|kotlin/Any| {
            public [ResolvedTo(STATUS)] [ContainingClassKey=Foo] constructor<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|>(): R|Foo<T>| {
                super<R|kotlin/Any|>()
            }

        }

        public final [ResolvedTo(RAW_FIR)] fun bar(): R|Foo<kotlin/String>?| {
            ^bar Null(null)
        }

        public final [ResolvedTo(RAW_FIR)] fun resolveMe(): R|kotlin/Unit| {
            [ResolvedTo(RAW_FIR)] lval x: R|Foo<kotlin/String>?| = R|/bar|()
        }


TYPES:
FILE: [ResolvedTo(IMPORTS)] functionCallWithGenericResultScript.kts
    context(<script>@R|kotlin/script/templates/standard/ScriptTemplateWithArgs|)
    SCRIPT: [ResolvedTo(BODY_RESOLVE)] 
        [ResolvedTo(RAW_FIR)] lval args: R|kotlin/Array<kotlin/String>|

        public open [ResolvedTo(STATUS)] class Foo<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|> : R|kotlin/Any| {
            public [ResolvedTo(STATUS)] [ContainingClassKey=Foo] constructor<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|>(): R|Foo<T>| {
                super<R|kotlin/Any|>()
            }

        }

        public final [ResolvedTo(RAW_FIR)] fun bar(): R|Foo<kotlin/String>?| {
            ^bar Null(null)
        }

        public final [ResolvedTo(RAW_FIR)] fun resolveMe(): R|kotlin/Unit| {
            [ResolvedTo(RAW_FIR)] lval x: R|Foo<kotlin/String>?| = R|/bar|()
        }


STATUS:
FILE: [ResolvedTo(IMPORTS)] functionCallWithGenericResultScript.kts
    context(<script>@R|kotlin/script/templates/standard/ScriptTemplateWithArgs|)
    SCRIPT: [ResolvedTo(BODY_RESOLVE)] 
        [ResolvedTo(RAW_FIR)] lval args: R|kotlin/Array<kotlin/String>|

        public open [ResolvedTo(STATUS)] class Foo<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|> : R|kotlin/Any| {
            public [ResolvedTo(STATUS)] [ContainingClassKey=Foo] constructor<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|>(): R|Foo<T>| {
                super<R|kotlin/Any|>()
            }

        }

        public final [ResolvedTo(RAW_FIR)] fun bar(): R|Foo<kotlin/String>?| {
            ^bar Null(null)
        }

        public final [ResolvedTo(RAW_FIR)] fun resolveMe(): R|kotlin/Unit| {
            [ResolvedTo(RAW_FIR)] lval x: R|Foo<kotlin/String>?| = R|/bar|()
        }


EXPECT_ACTUAL_MATCHING:
FILE: [ResolvedTo(IMPORTS)] functionCallWithGenericResultScript.kts
    context(<script>@R|kotlin/script/templates/standard/ScriptTemplateWithArgs|)
    SCRIPT: [ResolvedTo(BODY_RESOLVE)] 
        [ResolvedTo(RAW_FIR)] lval args: R|kotlin/Array<kotlin/String>|

        public open [ResolvedTo(STATUS)] class Foo<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|> : R|kotlin/Any| {
            public [ResolvedTo(STATUS)] [ContainingClassKey=Foo] constructor<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|>(): R|Foo<T>| {
                super<R|kotlin/Any|>()
            }

        }

        public final [ResolvedTo(RAW_FIR)] fun bar(): R|Foo<kotlin/String>?| {
            ^bar Null(null)
        }

        public final [ResolvedTo(RAW_FIR)] fun resolveMe(): R|kotlin/Unit| {
            [ResolvedTo(RAW_FIR)] lval x: R|Foo<kotlin/String>?| = R|/bar|()
        }


ARGUMENTS_OF_ANNOTATIONS:
FILE: [ResolvedTo(IMPORTS)] functionCallWithGenericResultScript.kts
    context(<script>@R|kotlin/script/templates/standard/ScriptTemplateWithArgs|)
    SCRIPT: [ResolvedTo(BODY_RESOLVE)] 
        [ResolvedTo(RAW_FIR)] lval args: R|kotlin/Array<kotlin/String>|

        public open [ResolvedTo(STATUS)] class Foo<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|> : R|kotlin/Any| {
            public [ResolvedTo(STATUS)] [ContainingClassKey=Foo] constructor<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|>(): R|Foo<T>| {
                super<R|kotlin/Any|>()
            }

        }

        public final [ResolvedTo(RAW_FIR)] fun bar(): R|Foo<kotlin/String>?| {
            ^bar Null(null)
        }

        public final [ResolvedTo(RAW_FIR)] fun resolveMe(): R|kotlin/Unit| {
            [ResolvedTo(RAW_FIR)] lval x: R|Foo<kotlin/String>?| = R|/bar|()
        }


CONTRACTS:
FILE: [ResolvedTo(IMPORTS)] functionCallWithGenericResultScript.kts
    context(<script>@R|kotlin/script/templates/standard/ScriptTemplateWithArgs|)
    SCRIPT: [ResolvedTo(BODY_RESOLVE)] 
        [ResolvedTo(RAW_FIR)] lval args: R|kotlin/Array<kotlin/String>|

        public open [ResolvedTo(STATUS)] class Foo<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|> : R|kotlin/Any| {
            public [ResolvedTo(STATUS)] [ContainingClassKey=Foo] constructor<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|>(): R|Foo<T>| {
                super<R|kotlin/Any|>()
            }

        }

        public final [ResolvedTo(RAW_FIR)] fun bar(): R|Foo<kotlin/String>?| {
            ^bar Null(null)
        }

        public final [ResolvedTo(RAW_FIR)] fun resolveMe(): R|kotlin/Unit| {
            [ResolvedTo(RAW_FIR)] lval x: R|Foo<kotlin/String>?| = R|/bar|()
        }


IMPLICIT_TYPES_BODY_RESOLVE:
FILE: [ResolvedTo(IMPORTS)] functionCallWithGenericResultScript.kts
    context(<script>@R|kotlin/script/templates/standard/ScriptTemplateWithArgs|)
    SCRIPT: [ResolvedTo(BODY_RESOLVE)] 
        [ResolvedTo(RAW_FIR)] lval args: R|kotlin/Array<kotlin/String>|

        public open [ResolvedTo(STATUS)] class Foo<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|> : R|kotlin/Any| {
            public [ResolvedTo(STATUS)] [ContainingClassKey=Foo] constructor<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|>(): R|Foo<T>| {
                super<R|kotlin/Any|>()
            }

        }

        public final [ResolvedTo(RAW_FIR)] fun bar(): R|Foo<kotlin/String>?| {
            ^bar Null(null)
        }

        public final [ResolvedTo(RAW_FIR)] fun resolveMe(): R|kotlin/Unit| {
            [ResolvedTo(RAW_FIR)] lval x: R|Foo<kotlin/String>?| = R|/bar|()
        }


ANNOTATIONS_ARGUMENTS_MAPPING:
FILE: [ResolvedTo(IMPORTS)] functionCallWithGenericResultScript.kts
    context(<script>@R|kotlin/script/templates/standard/ScriptTemplateWithArgs|)
    SCRIPT: [ResolvedTo(BODY_RESOLVE)] 
        [ResolvedTo(RAW_FIR)] lval args: R|kotlin/Array<kotlin/String>|

        public open [ResolvedTo(STATUS)] class Foo<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|> : R|kotlin/Any| {
            public [ResolvedTo(STATUS)] [ContainingClassKey=Foo] constructor<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|>(): R|Foo<T>| {
                super<R|kotlin/Any|>()
            }

        }

        public final [ResolvedTo(RAW_FIR)] fun bar(): R|Foo<kotlin/String>?| {
            ^bar Null(null)
        }

        public final [ResolvedTo(RAW_FIR)] fun resolveMe(): R|kotlin/Unit| {
            [ResolvedTo(RAW_FIR)] lval x: R|Foo<kotlin/String>?| = R|/bar|()
        }


BODY_RESOLVE:
FILE: [ResolvedTo(IMPORTS)] functionCallWithGenericResultScript.kts
    context(<script>@R|kotlin/script/templates/standard/ScriptTemplateWithArgs|)
    SCRIPT: [ResolvedTo(BODY_RESOLVE)] 
        [ResolvedTo(RAW_FIR)] lval args: R|kotlin/Array<kotlin/String>|

        public open [ResolvedTo(STATUS)] class Foo<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|> : R|kotlin/Any| {
            public [ResolvedTo(STATUS)] [ContainingClassKey=Foo] constructor<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|>(): R|Foo<T>| {
                super<R|kotlin/Any|>()
            }

        }

        public final [ResolvedTo(RAW_FIR)] fun bar(): R|Foo<kotlin/String>?| {
            ^bar Null(null)
        }

        public final [ResolvedTo(RAW_FIR)] fun resolveMe(): R|kotlin/Unit| {
            [ResolvedTo(RAW_FIR)] lval x: R|Foo<kotlin/String>?| = R|/bar|()
        }


FILE RAW TO BODY:
FILE: [ResolvedTo(IMPORTS)] functionCallWithGenericResultScript.kts
    context(<script>@R|kotlin/script/templates/standard/ScriptTemplateWithArgs|)
    SCRIPT: [ResolvedTo(BODY_RESOLVE)] 
        [ResolvedTo(RAW_FIR)] lval args: R|kotlin/Array<kotlin/String>|

        public open [ResolvedTo(STATUS)] class Foo<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|> : R|kotlin/Any| {
            public [ResolvedTo(STATUS)] [ContainingClassKey=Foo] constructor<[ResolvedTo(STATUS)] T : R|kotlin/CharSequence|>(): R|Foo<T>| {
                super<R|kotlin/Any|>()
            }

        }

        public final [ResolvedTo(RAW_FIR)] fun bar(): R|Foo<kotlin/String>?| {
            ^bar Null(null)
        }

        public final [ResolvedTo(RAW_FIR)] fun resolveMe(): R|kotlin/Unit| {
            [ResolvedTo(RAW_FIR)] lval x: R|Foo<kotlin/String>?| = R|/bar|()
        }

