[FIR] Synthetic property symbol is now a property symbol, not a function

This commit is contained in:
Mikhail Glukhikh
2020-02-05 12:44:53 +03:00
parent 17e1f081c7
commit 69809fef94
6 changed files with 277 additions and 17 deletions
@@ -2,12 +2,12 @@ FILE fqName:<root> fileName:/javaSyntheticPropertyAccess.kt
FUN name:test visibility:public modality:FINAL <> (j:<root>.J) returnType:kotlin.Unit
VALUE_PARAMETER name:j index:0 type:<root>.J
BLOCK_BODY
CALL 'public open fun getFoo (): kotlin.Int [operator] declared in <root>.J' type=kotlin.Int origin=GET_PROPERTY
CALL 'public open fun <get-foo> (): kotlin.Int declared in <root>.J' type=kotlin.Int origin=null
$this: GET_VAR 'j: <root>.J declared in <root>.test' type=<root>.J origin=null
ERROR_CALL 'Unresolved reference: R|/J.foo|' type=IrErrorType
VAR IR_TEMPORARY_VARIABLE name:tmp_0 type:kotlin.Int [val]
CALL 'public open fun getFoo (): kotlin.Int [operator] declared in <root>.J' type=kotlin.Int origin=GET_PROPERTY
CALL 'public open fun <get-foo> (): kotlin.Int declared in <root>.J' type=kotlin.Int origin=null
$this: GET_VAR 'j: <root>.J declared in <root>.test' type=<root>.J origin=null
ERROR_CALL 'Unresolved reference: R|/J.foo|' type=IrErrorType
GET_VAR 'val tmp_0: kotlin.Int [val] declared in <root>.test' type=kotlin.Int origin=null
ERROR_CALL 'Unresolved reference: <Variable expected>#' type=IrErrorType
ERROR_CALL 'Unresolved reference: R|/J.foo|' type=IrErrorType
@@ -2,7 +2,7 @@ FILE fqName:<root> fileName:/javaSyntheticProperty.kt
PROPERTY name:test visibility:public modality:FINAL [val]
FIELD PROPERTY_BACKING_FIELD name:test type:kotlin.String? visibility:private [final,static]
EXPRESSION_BODY
CALL 'public open fun getFoo (): kotlin.String? [operator] declared in <root>.J' type=kotlin.String? origin=GET_PROPERTY
CALL 'public open fun <get-foo> (): kotlin.String? declared in <root>.J' type=kotlin.String? origin=null
$this: CONSTRUCTOR_CALL 'public/*package*/ constructor <init> () [primary] declared in <root>.J' type=<root>.J origin=null
FUN DEFAULT_PROPERTY_ACCESSOR name:<get-test> visibility:public modality:FINAL <> () returnType:kotlin.String?
correspondingProperty: PROPERTY name:test visibility:public modality:FINAL [val]
@@ -4,5 +4,5 @@ FILE fqName:<root> fileName:/jdkClassSyntheticProperty.kt
correspondingProperty: PROPERTY name:test visibility:public modality:FINAL [val]
BLOCK_BODY
RETURN type=kotlin.Nothing from='public final fun <get-test> (): kotlin.Array<out java.lang.reflect.Field?>? declared in <root>'
CALL 'public open fun getDeclaredFields (): kotlin.Array<out java.lang.reflect.Field?>? [operator] declared in java.lang.Class' type=kotlin.Array<out java.lang.reflect.Field?>? origin=GET_PROPERTY
CALL 'public open fun <get-declaredFields> (): kotlin.Array<out java.lang.reflect.Field?>? declared in java.lang.Class' type=kotlin.Array<out java.lang.reflect.Field?>? origin=null
$this: ERROR_CALL 'Unresolved reference: this@R|/test|' type=java.lang.Class<*>