我在尝试在多模块项目中添加jetpack compose时遇到问题 我正在使用Android Studio 4.2 Canary 3
失败的gradle任务是:module:compileDebugKotlin,出现此错误消息
e: java.lang.IllegalStateException: Backend Internal error: Exception during code generation
我的:module build.gradle看起来像这样
android {
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
kotlinOptions {
jvmTarget = "1.8"
// Compose compiler based on 1.4 but set 1.3 for compatibility
apiVersion = "1.3"
}
buildFeatures {
compose true
}
composeOptions {
kotlinCompilerVersion "1.3.70-dev-withExperimentalGoogleExtensions-20200424"
kotlinCompilerExtensionVersion "0.1.0-dev14"
}
}
有人知道如何解决这个问题吗?
完整堆栈跟踪为
e: java.lang.IllegalStateException: Backend Internal error: Exception during code generation
File being compiled: /Users/Streetwizard/Documents/Formiik/formiik-android/FormiikFXL/login/src/main/java/com/kata/formiik/login/LoginActivity.kt
The root cause java.lang.RuntimeException was thrown at: org.jetbrains.kotlin.backend.jvm.codegen.FunctionCodegen.generate(FunctionCodegen.kt:53)
at org.jetbrains.kotlin.backend.common.CodegenUtil.reportBackendException(CodegenUtil.kt:247)
at org.jetbrains.kotlin.backend.jvm.JvmBackendFacade.doGenerateFilesInternal$backend_jvm(JvmBackendFacade.kt:99)
at org.jetbrains.kotlin.backend.jvm.JvmBackendFacade.doGenerateFiles(JvmBackendFacade.kt:52)
at org.jetbrains.kotlin.backend.jvm.JvmIrCodegenFactory.generateModule(JvmIrCodegenFactory.kt:37)
at org.jetbrains.kotlin.codegen.KotlinCodegenFacade.compileCorrectFiles(KotlinCodegenFacade.java:35)
at org.jetbrains.kotlin.cli.jvm.compiler.KotlinToJVMBytecodeCompiler.generate(KotlinToJVMBytecodeCompiler.kt:635)
at org.jetbrains.kotlin.cli.jvm.compiler.KotlinToJVMBytecodeCompiler.compileModules$cli(KotlinToJVMBytecodeCompiler.kt:194)
at org.jetbrains.kotlin.cli.jvm.K2JVMCompiler.doExecute(K2JVMCompiler.kt:163)
at org.jetbrains.kotlin.cli.jvm.K2JVMCompiler.doExecute(K2JVMCompiler.kt:51)
at org.jetbrains.kotlin.cli.common.CLICompiler.execImpl(CLICompiler.kt:86)
at org.jetbrains.kotlin.cli.common.CLICompiler.execImpl(CLICompiler.kt:44)
at org.jetbrains.kotlin.cli.common.CLITool.exec(CLITool.kt:104)
at org.jetbrains.kotlin.incremental.IncrementalJvmCompilerRunner.runCompiler(IncrementalJvmCompilerRunner.kt:346)
at org.jetbrains.kotlin.incremental.IncrementalJvmCompilerRunner.runCompiler(IncrementalJvmCompilerRunner.kt:102)
at org.jetbrains.kotlin.incremental.IncrementalCompilerRunner.compileIncrementally(IncrementalCompilerRunner.kt:240)
at org.jetbrains.kotlin.incremental.IncrementalCompilerRunner.access$compileIncrementally(IncrementalCompilerRunner.kt:39)
at org.jetbrains.kotlin.incremental.IncrementalCompilerRunner$compile$2.invoke(IncrementalCompilerRunner.kt:81)
at org.jetbrains.kotlin.incremental.IncrementalCompilerRunner.compile(IncrementalCompilerRunner.kt:93)
at org.jetbrains.kotlin.daemon.CompileServiceImplBase.execIncrementalCompiler(CompileServiceImpl.kt:606)
at org.jetbrains.kotlin.daemon.CompileServiceImplBase.access$execIncrementalCompiler(CompileServiceImpl.kt:99)
at org.jetbrains.kotlin.daemon.CompileServiceImpl.compile(CompileServiceImpl.kt:1645)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:357)
at sun.rmi.transport.Transport$1.run(Transport.java:200)
at sun.rmi.transport.Transport$1.run(Transport.java:197)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.Transport.serviceCall(Transport.java:196)
at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:573)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run0(TCPTransport.java:834)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.lambda$run$0(TCPTransport.java:688)
at java.security.AccessController.doPrivileged(Native Method)
at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:687)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
at java.lang.Thread.run(Thread.java:748)
Caused by: java.lang.RuntimeException: Exception while generating code for:
FUN name:onCreate visibility:protected modality:OPEN <> ($this:com.kata.formiik.login.LoginActivity, savedInstanceState:android.os.Bundle?) returnType:kotlin.Unit
overridden:
protected/*protected and package*/ open fun onCreate (p0: android.os.Bundle?): kotlin.Unit declared in androidx.appcompat.app.AppCompatActivity
$this: VALUE_PARAMETER name:<this> type:com.kata.formiik.login.LoginActivity
VALUE_PARAMETER name:savedInstanceState index:0 type:android.os.Bundle?
BLOCK_BODY
CALL 'protected/*protected and package*/ open fun onCreate (p0: android.os.Bundle?): kotlin.Unit declared in androidx.appcompat.app.AppCompatActivity' superQualifier='CLASS IR_EXTERNAL_JAVA_DECLARATION_STUB CLASS name:AppCompatActivity modality:OPEN visibility:public superTypes:[androidx.fragment.app.FragmentActivity; androidx.appcompat.app.AppCompatCallback; androidx.core.app.TaskStackBuilder.SupportParentable; androidx.appcompat.app.ActionBarDrawerToggle.DelegateProvider]' type=kotlin.Unit origin=null
$this: GET_VAR '<this>: com.kata.formiik.login.LoginActivity declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.kata.formiik.login.LoginActivity origin=null
p0: GET_VAR 'savedInstanceState: android.os.Bundle? declared in com.kata.formiik.login.LoginActivity.onCreate' type=android.os.Bundle? origin=null
WHEN type=kotlin.Unit origin=IF
BRANCH
if: CALL 'public final fun not (): kotlin.Boolean [operator] declared in kotlin.Boolean' type=kotlin.Boolean origin=EXCL
$this: CALL 'public open fun isTaskRoot (): kotlin.Boolean [fake_override] declared in com.kata.formiik.login.LoginActivity' type=kotlin.Boolean origin=GET_PROPERTY
$this: GET_VAR '<this>: com.kata.formiik.login.LoginActivity declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.kata.formiik.login.LoginActivity origin=null
then: BLOCK type=kotlin.Unit origin=null
VAR name:intentAction type:kotlin.String? [val]
CALL 'public open fun getAction (): kotlin.String? declared in android.content.Intent' type=kotlin.String? origin=GET_PROPERTY
$this: CALL 'public open fun getIntent (): android.content.Intent? [fake_override] declared in com.kata.formiik.login.LoginActivity' type=android.content.Intent? origin=GET_PROPERTY
$this: GET_VAR '<this>: com.kata.formiik.login.LoginActivity declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.kata.formiik.login.LoginActivity origin=null
WHEN type=kotlin.Unit origin=IF
BRANCH
if: CALL 'public final fun ANDAND (arg0: kotlin.Boolean, arg1: kotlin.Boolean): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=null
arg0: CALL 'public final fun ANDAND (arg0: kotlin.Boolean, arg1: kotlin.Boolean): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=null
arg0: CALL 'public open fun hasCategory (p0: kotlin.String?): kotlin.Boolean declared in android.content.Intent' type=kotlin.Boolean origin=null
$this: CALL 'public open fun getIntent (): android.content.Intent? [fake_override] declared in com.kata.formiik.login.LoginActivity' type=android.content.Intent? origin=GET_PROPERTY
$this: GET_VAR '<this>: com.kata.formiik.login.LoginActivity declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.kata.formiik.login.LoginActivity origin=null
p0: CONST String type=kotlin.String value="android.intent.category.LAUNCHER"
arg1: CALL 'public final fun not (): kotlin.Boolean [operator] declared in kotlin.Boolean' type=kotlin.Boolean origin=EXCLEQ
$this: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EXCLEQ
arg0: GET_VAR 'val intentAction: kotlin.String? [val] declared in com.kata.formiik.login.LoginActivity.onCreate' type=kotlin.String? origin=null
arg1: CONST Null type=kotlin.Nothing? value=null
arg1: CALL 'public final fun EQEQ (arg0: kotlin.Any?, arg1: kotlin.Any?): kotlin.Boolean declared in kotlin.internal.ir' type=kotlin.Boolean origin=EQEQ
arg0: GET_VAR 'val intentAction: kotlin.String? [val] declared in com.kata.formiik.login.LoginActivity.onCreate' type=kotlin.String? origin=null
arg1: CONST String type=kotlin.String value="android.intent.action.MAIN"
then: BLOCK type=kotlin.Unit origin=null
CALL 'public open fun finish (): kotlin.Unit [fake_override] declared in com.kata.formiik.login.LoginActivity' type=kotlin.Unit origin=null
$this: GET_VAR '<this>: com.kata.formiik.login.LoginActivity declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.kata.formiik.login.LoginActivity origin=null
RETURN type=kotlin.Nothing from='protected open fun onCreate (savedInstanceState: android.os.Bundle?): kotlin.Unit declared in com.kata.formiik.login.LoginActivity'
GET_FIELD 'FIELD FIELD_FOR_OBJECT_INSTANCE name:INSTANCE type:kotlin.Unit visibility:public [final,static]' type=kotlin.Unit origin=null
CALL 'public open fun setContentView (p0: kotlin.Int): kotlin.Unit [fake_override] declared in com.kata.formiik.login.LoginActivity' type=kotlin.Unit origin=null
$this: GET_VAR '<this>: com.kata.formiik.login.LoginActivity declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.kata.formiik.login.LoginActivity origin=null
p0: GET_FIELD 'FIELD IR_EXTERNAL_JAVA_DECLARATION_STUB name:login_activity_login type:kotlin.Int visibility:public [static]' type=kotlin.Int origin=GET_PROPERTY
CALL 'private final fun initializeObservers (): kotlin.Unit declared in com.kata.formiik.login.LoginActivity' type=kotlin.Unit origin=null
$this: GET_VAR '<this>: com.kata.formiik.login.LoginActivity declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.kata.formiik.login.LoginActivity origin=null
CALL 'public open fun addTextChangedListener (p0: android.text.TextWatcher?): kotlin.Unit [fake_override] declared in com.google.android.material.textfield.TextInputEditText' type=kotlin.Unit origin=null
$this: CALL 'public final fun <get-activityLoginUserTextInputEditText> (): com.google.android.material.textfield.TextInputEditText? declared in kotlinx.android.synthetic.main.login_activity_login' type=com.google.android.material.textfield.TextInputEditText? origin=GET_PROPERTY
$receiver: GET_VAR '<this>: com.kata.formiik.login.LoginActivity declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.kata.formiik.login.LoginActivity origin=null
p0: GET_FIELD 'FIELD PROPERTY_BACKING_FIELD name:textWatcher type:android.text.TextWatcher visibility:private [final]' type=android.text.TextWatcher origin=GET_PROPERTY
receiver: GET_VAR '<this>: com.kata.formiik.login.LoginActivity declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.kata.formiik.login.LoginActivity origin=null
COMPOSITE type=kotlin.Unit origin=null
CALL 'public final fun addTextChangedListener$default (beforeTextChanged: kotlin.Function4<@[ParameterName(name = 'text')] kotlin.CharSequence?, @[ParameterName(name = 'start')] kotlin.Int, @[ParameterName(name = 'count')] kotlin.Int, @[ParameterName(name = 'after')] kotlin.Int, kotlin.Unit>?, onTextChanged: kotlin.Function4<@[ParameterName(name = 'text')] kotlin.CharSequence?, @[ParameterName(name = 'start')] kotlin.Int, @[ParameterName(name = 'before')] kotlin.Int, @[ParameterName(name = 'count')] kotlin.Int, kotlin.Unit>?, afterTextChanged: kotlin.Function1<@[ParameterName(name = 'text')] android.text.Editable?, kotlin.Unit>?, $mask0: kotlin.Int, $handler: kotlin.Any?): android.text.TextWatcher [inline] declared in androidx.core.widget.TextViewKt' type=android.text.TextWatcher origin=null
$receiver: BLOCK type=com.google.android.material.textfield.TextInputEditText origin=null
VAR IR_TEMPORARY_VARIABLE name:tmp0 type:com.google.android.material.textfield.TextInputEditText? [val]
CALL 'public final fun <get-activityLoginPasswordTextInputEditText> (): com.google.android.material.textfield.TextInputEditText? declared in kotlinx.android.synthetic.main.login_activity_login' type=com.google.android.material.textfield.TextInputEditText? origin=GET_PROPERTY
$receiver: GET_VAR '<this>: com.kata.formiik.login.LoginActivity declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.kata.formiik.login.LoginActivity origin=null
COMPOSITE type=com.google.android.material.textfield.TextInputEditText origin=null
CALL 'public final fun checkExpressionValueIsNotNull (value: kotlin.Any?, expression: kotlin.String): kotlin.Unit declared in kotlin.jvm.internal.Intrinsics' type=kotlin.Unit origin=null
value: GET_VAR 'val tmp0: com.google.android.material.textfield.TextInputEditText? [val] declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.google.android.material.textfield.TextInputEditText? origin=null
expression: CONST String type=kotlin.String value="this.activityLoginPasswordTextInputEditText"
GET_VAR 'val tmp0: com.google.android.material.textfield.TextInputEditText? [val] declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.google.android.material.textfield.TextInputEditText? origin=null
beforeTextChanged: COMPOSITE type=kotlin.Function4<@[ParameterName(name = 'text')] kotlin.CharSequence?, @[ParameterName(name = 'start')] kotlin.Int, @[ParameterName(name = 'count')] kotlin.Int, @[ParameterName(name = 'after')] kotlin.Int, kotlin.Unit>? origin=DEFAULT_VALUE
CONST Null type=kotlin.Function4<@[ParameterName(name = 'text')] kotlin.CharSequence?, @[ParameterName(name = 'start')] kotlin.Int, @[ParameterName(name = 'count')] kotlin.Int, @[ParameterName(name = 'after')] kotlin.Int, kotlin.Unit>? value=null
onTextChanged: COMPOSITE type=kotlin.Function4<@[ParameterName(name = 'text')] kotlin.CharSequence?, @[ParameterName(name = 'start')] kotlin.Int, @[ParameterName(name = 'before')] kotlin.Int, @[ParameterName(name = 'count')] kotlin.Int, kotlin.Unit>? origin=DEFAULT_VALUE
CONST Null type=kotlin.Function4<@[ParameterName(name = 'text')] kotlin.CharSequence?, @[ParameterName(name = 'start')] kotlin.Int, @[ParameterName(name = 'before')] kotlin.Int, @[ParameterName(name = 'count')] kotlin.Int, kotlin.Unit>? value=null
afterTextChanged: BLOCK type=kotlin.Function1<android.text.Editable?, kotlin.Unit> origin=LAMBDA
COMPOSITE type=kotlin.Unit origin=null
FUNCTION_REFERENCE 'private final fun onCreate$lambda-0 ($this: com.kata.formiik.login.LoginActivity, it: android.text.Editable?): kotlin.Unit declared in com.kata.formiik.login.LoginActivity' type=kotlin.Function1<android.text.Editable?, kotlin.Unit> origin=LAMBDA
$this: GET_VAR '<this>: com.kata.formiik.login.LoginActivity declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.kata.formiik.login.LoginActivity origin=null
$mask0: CONST Int type=kotlin.Int value=3
$handler: CONST Null type=kotlin.Any? value=null
COMPOSITE type=kotlin.Unit origin=null
CALL 'public open fun setOnClickListener (p0: android.view.View.OnClickListener?): kotlin.Unit [fake_override] declared in com.google.android.material.textview.MaterialTextView' type=kotlin.Unit origin=null
$this: CALL 'public final fun <get-activityLoginOAuthenticationLoginTextView> (): com.google.android.material.textview.MaterialTextView? declared in kotlinx.android.synthetic.main.login_activity_login' type=com.google.android.material.textview.MaterialTextView? origin=GET_PROPERTY
$receiver: GET_VAR '<this>: com.kata.formiik.login.LoginActivity declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.kata.formiik.login.LoginActivity origin=null
p0: BLOCK type=com.kata.formiik.login.LoginActivity.onCreate.<no name provided> origin=null
CLASS LAMBDA_IMPL CLASS name:<no name provided> modality:FINAL visibility:public/*package*/ superTypes:[android.view.View.OnClickListener?]
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:com.kata.formiik.login.LoginActivity.onCreate.<no name provided>
FIELD FAKE_OVERRIDE name:receiver type:kotlin.Any? visibility:protected [fake_override]
CONSTRUCTOR GENERATED_MEMBER_IN_CALLABLE_REFERENCE visibility:public/*package*/ <> ($this:com.kata.formiik.login.LoginActivity) returnType:com.kata.formiik.login.LoginActivity.onCreate.<no name provided> [primary]
VALUE_PARAMETER BOUND_RECEIVER_PARAMETER name:$this index:0 type:com.kata.formiik.login.LoginActivity
BLOCK_BODY
SET_FIELD 'FIELD FIELD_FOR_CAPTURED_VALUE name:$this type:com.kata.formiik.login.LoginActivity visibility:private [final]' type=kotlin.Unit origin=INITIALIZER_OF_FIELD_FOR_CAPTURED_VALUE
receiver: GET_VAR '<this>: com.kata.formiik.login.LoginActivity.onCreate.<no name provided> declared in com.kata.formiik.login.LoginActivity.onCreate.<no name provided>' type=com.kata.formiik.login.LoginActivity.onCreate.<no name provided> origin=null
value: GET_VAR '$this: com.kata.formiik.login.LoginActivity declared in com.kata.formiik.login.LoginActivity.onCreate.<no name provided>.<init>' type=com.kata.formiik.login.LoginActivity origin=null
DELEGATING_CONSTRUCTOR_CALL 'public constructor <init> () [primary] declared in kotlin.Any'
BLOCK type=kotlin.Unit origin=null
FUN name:onClick visibility:public modality:FINAL <> ($this:com.kata.formiik.login.LoginActivity.onCreate.<no name provided>, it:android.view.View?) returnType:kotlin.Unit
overridden:
public abstract fun onClick (p0: android.view.View?): kotlin.Unit declared in android.view.View.OnClickListener
$this: VALUE_PARAMETER INSTANCE_RECEIVER name:<this> type:com.kata.formiik.login.LoginActivity.onCreate.<no name provided>
VALUE_PARAMETER name:it index:0 type:android.view.View?
BLOCK_BODY
CALL 'public final fun launchOAuthentication (): kotlin.Unit declared in com.kata.formiik.login.LoginViewModel' type=kotlin.Unit origin=null
$this: CALL 'public final fun access$getViewModel ($this: com.kata.formiik.login.LoginActivity): com.kata.formiik.login.LoginViewModel declared in com.kata.formiik.login.LoginActivity' type=com.kata.formiik.login.LoginViewModel origin=GET_PROPERTY
$this: GET_FIELD 'FIELD FIELD_FOR_CAPTURED_VALUE name:$this type:com.kata.formiik.login.LoginActivity visibility:private [final]' type=com.kata.formiik.login.LoginActivity origin=null
receiver: GET_VAR '<this>: com.kata.formiik.login.LoginActivity.onCreate.<no name provided> declared in com.kata.formiik.login.LoginActivity.onCreate.<no name provided>.onClick' type=com.kata.formiik.login.LoginActivity.onCreate.<no name provided> origin=null
FIELD FIELD_FOR_CAPTURED_VALUE name:$this type:com.kata.formiik.login.LoginActivity visibility:private [final]
CONSTRUCTOR_CALL 'public/*package*/ constructor <init> ($this: com.kata.formiik.login.LoginActivity) [primary] declared in com.kata.formiik.login.LoginActivity.onCreate.<no name provided>' type=com.kata.formiik.login.LoginActivity.onCreate.<no name provided> origin=null
$this: GET_VAR '<this>: com.kata.formiik.login.LoginActivity declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.kata.formiik.login.LoginActivity origin=null
CALL 'public final fun setText (p0: kotlin.CharSequence?): kotlin.Unit [fake_override] declared in com.google.android.material.textfield.TextInputEditText' type=kotlin.Unit origin=null
$this: CALL 'public final fun <get-activityLoginPasswordTextInputEditText> (): com.google.android.material.textfield.TextInputEditText? declared in kotlinx.android.synthetic.main.login_activity_login' type=com.google.android.material.textfield.TextInputEditText? origin=GET_PROPERTY
$receiver: GET_VAR '<this>: com.kata.formiik.login.LoginActivity declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.kata.formiik.login.LoginActivity origin=null
p0: CALL 'public final fun <get-previouslyLoggedPassword> (): kotlin.String declared in com.kata.formiik.login.LoginViewModel' type=kotlin.String origin=GET_PROPERTY
$this: CALL 'private final fun <get-viewModel> (): com.kata.formiik.login.LoginViewModel declared in com.kata.formiik.login.LoginActivity' type=com.kata.formiik.login.LoginViewModel origin=GET_PROPERTY
$this: GET_VAR '<this>: com.kata.formiik.login.LoginActivity declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.kata.formiik.login.LoginActivity origin=null
CALL 'public final fun setText (p0: kotlin.CharSequence?): kotlin.Unit [fake_override] declared in com.google.android.material.textview.MaterialTextView' type=kotlin.Unit origin=EQ
$this: CALL 'public final fun <get-activityLoginVersionTextView> (): com.google.android.material.textview.MaterialTextView? declared in kotlinx.android.synthetic.main.login_activity_login' type=com.google.android.material.textview.MaterialTextView? origin=GET_PROPERTY
$receiver: GET_VAR '<this>: com.kata.formiik.login.LoginActivity declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.kata.formiik.login.LoginActivity origin=null
p0: CALL 'public final fun <get-informationVersion> (): kotlin.String declared in com.kata.formiik.login.LoginViewModel' type=kotlin.String origin=GET_PROPERTY
$this: CALL 'private final fun <get-viewModel> (): com.kata.formiik.login.LoginViewModel declared in com.kata.formiik.login.LoginActivity' type=com.kata.formiik.login.LoginViewModel origin=GET_PROPERTY
$this: GET_VAR '<this>: com.kata.formiik.login.LoginActivity declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.kata.formiik.login.LoginActivity origin=null
CALL 'private final fun requestMissingPermissions (): kotlin.Unit declared in com.kata.formiik.login.LoginActivity' type=kotlin.Unit origin=null
$this: GET_VAR '<this>: com.kata.formiik.login.LoginActivity declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.kata.formiik.login.LoginActivity origin=null
CALL 'private final fun setupTestEnvironmentButton (): kotlin.Unit declared in com.kata.formiik.login.LoginActivity' type=kotlin.Unit origin=null
$this: GET_VAR '<this>: com.kata.formiik.login.LoginActivity declared in com.kata.formiik.login.LoginActivity.onCreate' type=com.kata.formiik.login.LoginActivity origin=null
at org.jetbrains.kotlin.backend.jvm.codegen.FunctionCodegen.generate(FunctionCodegen.kt:53)
at org.jetbrains.kotlin.backend.jvm.codegen.ClassCodegen.generateMethod(ClassCodegen.kt:342)
at org.jetbrains.kotlin.backend.jvm.codegen.ClassCodegen.generateDeclaration(ClassCodegen.kt:302)
at org.jetbrains.kotlin.backend.jvm.codegen.ClassCodegen.generate(ClassCodegen.kt:148)
at org.jetbrains.kotlin.backend.jvm.codegen.ClassCodegen$Companion.generate(ClassCodegen.kt:290)
at org.jetbrains.kotlin.backend.jvm.JvmBackendFacade.doGenerateFilesInternal$backend_jvm(JvmBackendFacade.kt:95)
... 36 more
Caused by: java.lang.IllegalArgumentException: Unhandled intrinsic in ExpressionCodegen: FUN IR_EXTERNAL_DECLARATION_STUB name:<get-activityLoginUserTextInputEditText> visibility:public modality:FINAL <> ($receiver:android.app.Activity) returnType:com.google.android.material.textfield.TextInputEditText?
at org.jetbrains.kotlin.backend.jvm.codegen.ExpressionCodegen.visitFunctionAccess(ExpressionCodegen.kt:373)
at org.jetbrains.kotlin.backend.jvm.codegen.ExpressionCodegen.visitCall(ExpressionCodegen.kt:365)
at org.jetbrains.kotlin.backend.jvm.codegen.ExpressionCodegen.visitCall(ExpressionCodegen.kt:104)
at org.jetbrains.kotlin.ir.expressions.impl.IrCallImpl.accept(IrCallImpl.kt:78)
at org.jetbrains.kotlin.backend.jvm.codegen.ExpressionCodegen.gen(ExpressionCodegen.kt:171)
at org.jetbrains.kotlin.backend.jvm.codegen.IrCallGenerator$DefaultImpls.genValueAndPut(IrCallGenerator.kt:42)
at org.jetbrains.kotlin.backend.jvm.codegen.IrCallGenerator$DefaultCallGenerator.genValueAndPut(IrCallGenerator.kt:45)
at org.jetbrains.kotlin.backend.jvm.codegen.ExpressionCodegen.visitFunctionAccess(ExpressionCodegen.kt:411)
at org.jetbrains.kotlin.backend.jvm.codegen.ExpressionCodegen.visitCall(ExpressionCodegen.kt:365)
at org.jetbrains.kotlin.backend.jvm.codegen.ExpressionCodegen.visitCall(ExpressionCodegen.kt:104)
at org.jetbrains.kotlin.ir.expressions.impl.IrCallImpl.accept(IrCallImpl.kt:78)
at org.jetbrains.kotlin.backend.jvm.codegen.ExpressionCodegen.visitStatementContainer(ExpressionCodegen.kt:355)
at org.jetbrains.kotlin.backend.jvm.codegen.ExpressionCodegen.visitBlockBody(ExpressionCodegen.kt:359)
at org.jetbrains.kotlin.backend.jvm.codegen.ExpressionCodegen.visitBlockBody(ExpressionCodegen.kt:104)
at org.jetbrains.kotlin.ir.expressions.impl.IrBlockBodyImpl.accept(IrBlockBodyImpl.kt:40)
at org.jetbrains.kotlin.backend.jvm.codegen.ExpressionCodegen.generate(ExpressionCodegen.kt:200)
at org.jetbrains.kotlin.backend.jvm.codegen.FunctionCodegen.doGenerate(FunctionCodegen.kt:100)
at org.jetbrains.kotlin.backend.jvm.codegen.FunctionCodegen.generate(FunctionCodegen.kt:51)
... 41 more
e: java.lang.IllegalStateException: Backend Internal error: Exception during code generation
Execution failed for task ':login:compileDebugKotlin'.
> Internal compiler error. See log for more details
答案 0 :(得分:0)
存在相同的问题,但这不是由模块引起的,而是由android studio的问题引起的,它对我适用于android studio 4.1 canary 10且具有相同的构建参数
答案 1 :(得分:0)
如果您使用的是Kotlin Synthetics,请尝试更改为已定义的视图绑定。集成Twilio时遇到了类似的错误,此错误已得到解决。祝你好运!