Fix for KT-15575: VerifyError: Bad type on operand stack

#KT-15575 Fixed
This commit is contained in:
Mikhael Bogdanov
2017-01-09 17:50:11 +01:00
parent a3f6fbe0c1
commit 2931c316a3
14 changed files with 123 additions and 4 deletions
@@ -21,6 +21,7 @@ import com.sun.tools.javac.tree.JCTree
import com.sun.tools.javac.tree.TreeMaker
import com.sun.tools.javac.util.Context
import com.sun.tools.javac.util.Names
import org.jetbrains.kotlin.codegen.AsmUtil
import org.jetbrains.org.objectweb.asm.Type
import org.jetbrains.org.objectweb.asm.Type.*
@@ -30,7 +31,7 @@ class KaptTreeMaker(context: Context) : TreeMaker(context) {
fun Type(type: Type): JCTree.JCExpression {
convertBuiltinType(type)?.let { return it }
if (type.sort == ARRAY) {
return TypeArray(Type(type.elementType))
return TypeArray(Type(AsmUtil.correctElementType(type)))
}
return FqName(type.className)
}