[FIR] FirComponentCall rendered same as FirFunctionCall

This commit is contained in:
Dmitriy Novozhilov
2020-02-25 16:11:25 +03:00
parent 266149b88c
commit 807d41028e
5 changed files with 10 additions and 12 deletions
@@ -31,6 +31,6 @@ FILE: annotated.kt
}
public? final? fun bar(two: Two): R|kotlin/Unit| {
lval <destruct>: <implicit> = two#
@Ann() lval x: <implicit> = R|<local>/<destruct>|.component1()
@Ann() lval y: <implicit> = R|<local>/<destruct>|.component2()
@Ann() lval x: <implicit> = R|<local>/<destruct>|.component1#()
@Ann() lval y: <implicit> = R|<local>/<destruct>|.component2#()
}
@@ -31,9 +31,9 @@ FILE: destructuring.kt
}
public? final? fun foo(some: Some): R|kotlin/Unit| {
lval <destruct>: <implicit> = some#
lvar x: <implicit> = R|<local>/<destruct>|.component1()
lvar y: <implicit> = R|<local>/<destruct>|.component2()
lvar z: String = R|<local>/<destruct>|.component3()
lvar x: <implicit> = R|<local>/<destruct>|.component1#()
lvar y: <implicit> = R|<local>/<destruct>|.component2#()
lvar z: String = R|<local>/<destruct>|.component3#()
lval <unary>: <implicit> = x#
x# = R|<local>/<unary>|.inc#()
R|<local>/<unary>|
@@ -64,8 +64,8 @@ FILE: for.kt
lval <iterator>: <implicit> = set#.iterator#()
while(R|<local>/<iterator>|.hasNext#()) {
lval <destruct>: <implicit> = R|<local>/<iterator>|.next#()
lval x: <implicit> = R|<local>/<destruct>|.component1()
lval y: <implicit> = R|<local>/<destruct>|.component2()
lval x: <implicit> = R|<local>/<destruct>|.component1#()
lval y: <implicit> = R|<local>/<destruct>|.component2#()
println#(<strcat>(String(x = ), x#.toString#(), String( y = ), y#.toString#()))
}
@@ -33,8 +33,8 @@ FILE: lambda.kt
}
use#(<L> = use@fun <implicit>.<anonymous>(<destruct>: <implicit>): <implicit> {
lval x: <implicit> = R|<local>/<destruct>|.component1()
lval y: <implicit> = R|<local>/<destruct>|.component2()
lval x: <implicit> = R|<local>/<destruct>|.component1#()
lval y: <implicit> = R|<local>/<destruct>|.component2#()
x#.plus#(y#)
}
)
@@ -1027,9 +1027,7 @@ class FirRenderer(builder: StringBuilder, private val mode: RenderMode = RenderM
}
override fun visitComponentCall(componentCall: FirComponentCall) {
componentCall.annotations.renderAnnotations()
componentCall.explicitReceiver.accept(this)
print(".component${componentCall.componentIndex}()")
visitFunctionCall(componentCall)
}
override fun visitGetClassCall(getClassCall: FirGetClassCall) {