当我打开proguard时,Android Studio 3.1.2因StackOverFlowError而失败

时间:2018-05-09 20:01:29

标签: android gradle android-gradle

在升级到Android上的最新gradle 3.1.2后,我无法再用proguard编译我的项目。

我可以在没有启用proguard的情况下编译项目。但是,当我打开它时,如下所示

debug {
            minifyEnabled true
            shrinkResources true
            proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
            signingConfig signingConfigs.debugConfig
        }

项目无法编译,我看到此错误消息

Cause: java.lang.StackOverflowError
    at proguard.classfile.instruction.InstructionFactory.create(InstructionFactory.java:296)
    at proguard.classfile.attribute.visitor.StackSizeComputer.evaluateInstructionBlock(StackSizeComputer.java:325)
    at proguard.classfile.attribute.visitor.StackSizeComputer.visitBranchInstruction(StackSizeComputer.java:207)
    at proguard.classfile.instruction.BranchInstruction.accept(BranchInstruction.java:141)
    at proguard.classfile.attribute.visitor.StackSizeComputer.evaluateInstructionBlock(StackSizeComputer.java:366)
    at proguard.classfile.attribute.visitor.StackSizeComputer.visitBranchInstruction(StackSizeComputer.java:207)
    at proguard.classfile.instruction.BranchInstruction.accept(BranchInstruction.java:141)
    at proguard.classfile.attribute.visitor.StackSizeComputer.evaluateInstructionBlock(StackSizeComputer.java:366)
    at proguard.classfile.attribute.visitor.StackSizeComputer.visitBranchInstruction(StackSizeComputer.java:207)

什么会导致此错误?

0 个答案:

没有答案