172: Revert "Uast: AbstractKotlinUClass compilation fix"

This reverts commit 86ee036ae7d89f8acc885d54157d9b9ce5f2cb17.
This commit is contained in:
Nikolay Krasko
2018-01-11 20:12:00 +03:00
parent bf27a16144
commit 72b4b2b9bf
@@ -35,7 +35,7 @@ abstract class AbstractKotlinUClass(private val givenParent: UElement?) : Abstra
override val uastParent: UElement? by lz { givenParent ?: convertParent() }
//TODO: should be merged with KotlinAbstractUElement.convertParent() after detaching from AbstractJavaUClass
override fun convertParent(): UElement? =
open fun convertParent(): UElement? =
(this.psi as? KtLightClassForLocalDeclaration)?.kotlinOrigin?.parent?.let {
when (it) {
is KtClassBody -> it.parent.toUElement() // TODO: it seems that `class_body`-s are never created in kotlin uast in top-down walk, probably they should be completely skipped and always unwrapped