IrFunctionExpression: add 'origin'

This is actually either a LAMBDA or an ANONYMOUS_FUNCTION.
Not quite sure if it's really required, but some tools such as IR-based
decompiler might require this information.
This commit is contained in:
Dmitry Petrov
2019-07-15 13:09:48 +03:00
parent 41b59f9b9a
commit ffd9b45ef3
61 changed files with 121 additions and 96 deletions
@@ -4,7 +4,7 @@ FILE fqName:<root> fileName:/variableAsFunctionCallWithGenerics.kt
correspondingProperty: PROPERTY name:gk visibility:public modality:FINAL [val]
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun <get-gk> (): kotlin.Function0<T of <uninitialized parent>> declared in <root>'
FUN_EXPR type=kotlin.Function1<kotlin.Function0<T of <uninitialized parent>>, kotlin.Function0<T of <uninitialized parent>>>
FUN_EXPR type=kotlin.Function1<kotlin.Function0<T of <uninitialized parent>>, kotlin.Function0<T of <uninitialized parent>>> origin=LAMBDA
FUN LOCAL_FUNCTION_FOR_LAMBDA name:<anonymous> visibility:local modality:FINAL <> () returnType:kotlin.Function0<T of <uninitialized parent>>
BLOCK_BODY
ERROR_CALL 'Unresolved reference: this#' type=IrErrorType
@@ -19,7 +19,7 @@ FILE fqName:<root> fileName:/variableAsFunctionCallWithGenerics.kt
correspondingProperty: PROPERTY name:kt26531Val visibility:public modality:FINAL [val]
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun <get-kt26531Val> (): kotlin.Function0<T of <uninitialized parent>> declared in <root>'
FUN_EXPR type=kotlin.Function0<kotlin.Function0<T of <uninitialized parent>>>
FUN_EXPR type=kotlin.Function0<kotlin.Function0<T of <uninitialized parent>>> origin=LAMBDA
FUN name:<no name provided> visibility:local modality:FINAL <> () returnType:kotlin.Function0<T of <uninitialized parent>>
BLOCK_BODY
RETURN type=kotlin.Nothing from='local final fun <no name provided> (): kotlin.Function0<T of <uninitialized parent>> declared in <root>.<get-kt26531Val>'