Transformer error: IrCallImpl cannot be cast to class IrSetField
Closed this issue · 0 comments
eggnstone commented
Exception in thread "main" org.dotlin.compiler.backend.DotlinTransformerError: Transformer error occurred: class org.jetbrains.kotlin.ir.expressions.impl.IrCallImpl cannot be cast to class org.jetbrains.kotlin.ir.expressions.IrSetField (org.jetbrains.kotlin.ir.expressions.impl.IrCallImpl and org.jetbrains.kotlin.ir.expressions.IrSetField are in unnamed module of loader 'app')
While processing:
BLOCK type=kotlin.Unit origin=PLUSEQ
at org.dotlin.compiler.backend.ErrorsKt$runAndReportTransformerError$1.invoke(Errors.kt:117)
at org.dotlin.compiler.backend.ErrorsKt$runAndReportTransformerError$1.invoke(Errors.kt:117)
at org.dotlin.compiler.backend.ErrorsKt.runAndReport(Errors.kt:110)
at org.dotlin.compiler.backend.ErrorsKt.runAndReportTransformerError(Errors.kt:117)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer.visitBlock(IrDartAstTransformer.kt:48)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer.visitBlock(IrDartAstTransformer.kt:31)
at org.jetbrains.kotlin.ir.expressions.IrBlock.accept(IrBlock.kt:22)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartStatementKt.accept(IrToDartStatement.kt:371)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartStatementKt.accept(IrToDartStatement.kt:372)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartStatementTransformer.visitTry$lambda$6$acceptAsBlock(IrToDartStatement.kt:128)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartStatementTransformer.visitTry(IrToDartStatement.kt:132)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartStatementTransformer.visitTry(IrToDartStatement.kt:55)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer$visitTry$1$1.invoke(IrDartAstTransformer.kt:511)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer$visitTry$1$1.invoke(IrDartAstTransformer.kt:511)
at org.dotlin.compiler.backend.ErrorsKt.runAndReport(Errors.kt:107)
at org.dotlin.compiler.backend.ErrorsKt.runAndReportTransformerError(Errors.kt:117)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer.visitTry(IrDartAstTransformer.kt:511)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer.visitTry(IrDartAstTransformer.kt:31)
at org.jetbrains.kotlin.ir.expressions.IrTry.accept(IrTry.kt:27)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartStatementKt.acceptAsStatement(IrToDartStatement.kt:373)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartStatementTransformer.visitLoop(IrToDartStatement.kt:146)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartStatementTransformer.visitLoop(IrToDartStatement.kt:55)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer$visitLoop$1$1.invoke(IrDartAstTransformer.kt:380)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer$visitLoop$1$1.invoke(IrDartAstTransformer.kt:380)
at org.dotlin.compiler.backend.ErrorsKt.runAndReport(Errors.kt:107)
at org.dotlin.compiler.backend.ErrorsKt.runAndReportTransformerError(Errors.kt:117)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer.visitLoop(IrDartAstTransformer.kt:380)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer.visitLoop(IrDartAstTransformer.kt:31)
at org.jetbrains.kotlin.ir.visitors.IrElementVisitor$DefaultImpls.visitWhileLoop(IrElementVisitor.kt:278)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer.visitWhileLoop(IrDartAstTransformer.kt:570)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer$visitWhileLoop$1$1.invoke(IrDartAstTransformer.kt:567)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer$visitWhileLoop$1$1.invoke(IrDartAstTransformer.kt:567)
at org.dotlin.compiler.backend.ErrorsKt.runAndReport(Errors.kt:107)
at org.dotlin.compiler.backend.ErrorsKt.runAndReportTransformerError(Errors.kt:117)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer.visitWhileLoop(IrDartAstTransformer.kt:567)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer.visitWhileLoop(IrDartAstTransformer.kt:31)
at org.jetbrains.kotlin.ir.expressions.IrWhileLoop.accept(IrWhileLoop.kt:20)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartStatementKt.accept(IrToDartStatement.kt:371)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartStatementKt.accept(IrToDartStatement.kt:372)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartFunctionBodyTransformer.visitBlockBody(IrToDartFunctionBody.kt:45)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartFunctionBodyTransformer.visitBlockBody(IrToDartFunctionBody.kt:33)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer$visitBlockBody$1$1.invoke(IrDartAstTransformer.kt:54)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer$visitBlockBody$1$1.invoke(IrDartAstTransformer.kt:54)
at org.dotlin.compiler.backend.ErrorsKt.runAndReport(Errors.kt:107)
at org.dotlin.compiler.backend.ErrorsKt.runAndReportTransformerError(Errors.kt:117)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer.visitBlockBody(IrDartAstTransformer.kt:54)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer.visitBlockBody(IrDartAstTransformer.kt:31)
at org.jetbrains.kotlin.ir.expressions.IrBlockBody.accept(IrBlockBody.kt:24)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartFunctionBodyKt.accept(IrToDartFunctionBody.kt:62)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartFunctionBodyKt.accept$default(IrToDartFunctionBody.kt:59)
at org.dotlin.compiler.backend.steps.ir2ast.DartAstTransformContext.transformBy(DartAstTransformContext.kt:70)
at org.dotlin.compiler.backend.steps.ir2ast.DartAstTransformContext.transformBy(DartAstTransformContext.kt:93)
at org.dotlin.compiler.backend.steps.ir2ast.DartAstTransformContext.transformBy$default(DartAstTransformContext.kt:89)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartClassMemberTransformer.visitSimpleFunction(IrToDartClassMember.kt:49)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartClassMemberTransformer.visitSimpleFunction(IrToDartClassMember.kt:46)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer$visitSimpleFunction$1$1.invoke(IrDartAstTransformer.kt:454)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer$visitSimpleFunction$1$1.invoke(IrDartAstTransformer.kt:454)
at org.dotlin.compiler.backend.ErrorsKt.runAndReport(Errors.kt:107)
at org.dotlin.compiler.backend.ErrorsKt.runAndReportTransformerError(Errors.kt:117)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer.visitSimpleFunction(IrDartAstTransformer.kt:454)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer.visitSimpleFunction(IrDartAstTransformer.kt:31)
at org.jetbrains.kotlin.ir.declarations.IrSimpleFunction.accept(IrSimpleFunction.kt:36)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartClassMemberKt.acceptAsClassMember(IrToDartClassMember.kt:192)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartDeclarationTransformer$visitClass$members$3.invoke(IrToDartDeclaration.kt:147)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartDeclarationTransformer$visitClass$members$3.invoke(IrToDartDeclaration.kt:147)
at kotlin.sequences.TransformingSequence$iterator$1.next(Sequences.kt:210)
at kotlin.sequences.SequencesKt___SequencesKt.toCollection(_Sequences.kt:787)
at kotlin.sequences.SequencesKt___SequencesKt.toMutableList(_Sequences.kt:817)
at kotlin.sequences.SequencesKt___SequencesKt.toList(_Sequences.kt:808)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartDeclarationTransformer.visitClass(IrToDartDeclaration.kt:148)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartDeclarationTransformer.visitClass(IrToDartDeclaration.kt:42)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer$visitClass$1$1.invoke(IrDartAstTransformer.kt:98)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer$visitClass$1$1.invoke(IrDartAstTransformer.kt:98)
at org.dotlin.compiler.backend.ErrorsKt.runAndReport(Errors.kt:107)
at org.dotlin.compiler.backend.ErrorsKt.runAndReportTransformerError(Errors.kt:117)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer.visitClass(IrDartAstTransformer.kt:98)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer.visitClass(IrDartAstTransformer.kt:31)
at org.jetbrains.kotlin.ir.declarations.IrClass.accept(IrClass.kt:64)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartDeclarationKt.accept(IrToDartDeclaration.kt:224)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartCompilationUnitTransformer.visitFile(IrToDartCompilationUnit.kt:36)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartCompilationUnitTransformer.visitFile(IrToDartCompilationUnit.kt:32)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer$visitFile$1$1.invoke(IrDartAstTransformer.kt:283)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer$visitFile$1$1.invoke(IrDartAstTransformer.kt:283)
at org.dotlin.compiler.backend.ErrorsKt.runAndReport(Errors.kt:107)
at org.dotlin.compiler.backend.ErrorsKt.runAndReportTransformerError(Errors.kt:117)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer.visitFile(IrDartAstTransformer.kt:283)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer.visitFile(IrDartAstTransformer.kt:31)
at org.jetbrains.kotlin.ir.declarations.IrFile.accept(IrFile.kt:30)
at org.dotlin.compiler.backend.steps.ir2ast.IrToDartAstKt.irToDartAst(IrToDartAst.kt:58)
at org.dotlin.compiler.KotlinToDartCompiler.generateDartCode(KotlinToDartCompiler.kt:147)
at org.dotlin.compiler.KotlinToDartCompiler.compile(KotlinToDartCompiler.kt:77)
at org.dotlin.compiler.KotlinToDartCompiler.compile$default(KotlinToDartCompiler.kt:57)
at org.dotlin.compiler.KotlinToDartCompiler.compile(KotlinToDartCompiler.kt:52)
at org.dotlin.compiler.cli.command.Compile.run(Compile.kt:37)
at com.github.ajalt.clikt.parsers.Parser.parse(Parser.kt:198)
at com.github.ajalt.clikt.parsers.Parser.parse(Parser.kt:18)
at com.github.ajalt.clikt.core.CliktCommand.parse(CliktCommand.kt:400)
at com.github.ajalt.clikt.core.CliktCommand.parse$default(CliktCommand.kt:397)
at com.github.ajalt.clikt.core.CliktCommand.main(CliktCommand.kt:415)
at com.github.ajalt.clikt.core.CliktCommand.main(CliktCommand.kt:440)
at org.dotlin.compiler.Dotlin.main(Main.kt:26)
Caused by: java.lang.ClassCastException: class org.jetbrains.kotlin.ir.expressions.impl.IrCallImpl cannot be cast to class org.jetbrains.kotlin.ir.expressions.IrSetField (org.jetbrains.kotlin.ir.expressions.impl.IrCallImpl and org.jetbrains.kotlin.ir.expressions.IrSetField are in unnamed module of loader 'app')
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartStatementTransformer.visitBlock(IrToDartStatement.kt:384)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrToDartStatementTransformer.visitBlock(IrToDartStatement.kt:55)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer$visitBlock$1$1.invoke(IrDartAstTransformer.kt:48)
at org.dotlin.compiler.backend.steps.ir2ast.transformer.IrDartAstTransformer$visitBlock$1$1.invoke(IrDartAstTransformer.kt:48)
at org.dotlin.compiler.backend.ErrorsKt.runAndReport(Errors.kt:107)
... 98 more