FIR: Introduce function to render fir element with it's type

This commit is contained in:
Simon Ogorodnik
2019-03-14 17:50:03 +03:00
parent 24041828a9
commit b574693916
@@ -26,6 +26,11 @@ import org.jetbrains.kotlin.name.SpecialNames
import org.jetbrains.kotlin.types.Variance
import org.jetbrains.kotlin.utils.Printer
fun FirElement.renderWithType(): String = buildString {
append(this@renderWithType)
append(": ")
this@renderWithType.accept(FirRenderer(this))
}
fun FirElement.render(): String = buildString { this@render.accept(FirRenderer(this)) }