KT element: KtIfExpression
FIR element: FirWhenExpressionImpl
FIR source kind: KtRealSourceElementKind

FIR element rendered:
when () {
    (x# is String) ->  {
        String(1)
    }
    else ->  {
        String(2)
    }
}

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

        public? final? [ResolvedTo(RAW_FIR)] fun foo([ResolvedTo(RAW_FIR)] x: Any): String {
            ^foo when () {
                (x# is String) ->  {
                    String(1)
                }
                else ->  {
                    String(2)
                }
            }

        }