0

这是项目编译时的异常,环境是ubuntu 14.01LTS,ECLIPSE LUNA,还有eclipse Juno,gwt-eclipse-plugin,Java 1.7,

但是当我在没有 maven 项目的情况下创建时它编译得很好(新项目 - > google gwt)

Loading inherited module 'com.***.***.Application'
   Loading inherited module 'com.google.gwt.user.User'
      Loading inherited module 'com.google.gwt.core.Core'
     Loading inherited module 'com.google.gwt.core.CompilerParameters'
        [WARN] Setting configuration property named compiler.max.vars.per.var in com.google.gwt.core.CompilerParameters that has not been previously defined.  This may be disallowed in the future.
Compiling module com.***.***.Application
[ERROR] Unexpected internal compiler error
java.lang.ArrayIndexOutOfBoundsException: 0
    at com.google.gwt.dev.jjs.impl.GwtAstBuilder$AstVisitor.writeEnumValueOfMethod(GwtAstBuilder.java:2839)
    at com.google.gwt.dev.jjs.impl.GwtAstBuilder$AstVisitor.processEnumType(GwtAstBuilder.java:2488)
    at com.google.gwt.dev.jjs.impl.GwtAstBuilder$AstVisitor.endVisit(GwtAstBuilder.java:1921)
    at com.google.gwt.dev.jjs.impl.GwtAstBuilder$AstVisitor.endVisit(GwtAstBuilder.java:1604)
    at org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.traverse(TypeDeclaration.java:1441)
    at org.eclipse.jdt.internal.compiler.ast.TypeDeclaration.traverse(TypeDeclaration.java:1311)
    at com.google.gwt.dev.jjs.impl.GwtAstBuilder.process(GwtAstBuilder.java:3131)
    at com.google.gwt.dev.javac.CompilationStateBuilder$CompileMoreLater$UnitProcessorImpl.process(CompilationStateBuilder.java:127)
    at com.google.gwt.dev.javac.JdtCompiler$CompilerImpl.process(JdtCompiler.java:346)
    at org.eclipse.jdt.internal.compiler.Compiler.compile(Compiler.java:470)
    at com.google.gwt.dev.javac.JdtCompiler.doCompile(JdtCompiler.java:880)
    at com.google.gwt.dev.javac.CompilationStateBuilder$CompileMoreLater.compile(CompilationStateBuilder.java:284)
    at com.google.gwt.dev.javac.CompilationStateBuilder.doBuildFrom(CompilationStateBuilder.java:511)
    at com.google.gwt.dev.javac.CompilationStateBuilder.buildFrom(CompilationStateBuilder.java:434)
    at com.google.gwt.dev.javac.CompilationStateBuilder.buildFrom(CompilationStateBuilder.java:420)
    at com.google.gwt.dev.cfg.ModuleDef.getCompilationState(ModuleDef.java:485)
    at com.google.gwt.dev.Precompile.precompile(Precompile.java:241)
    at com.google.gwt.dev.Precompile.precompile(Precompile.java:223)
    at com.google.gwt.dev.Precompile.precompile(Precompile.java:139)
    at com.google.gwt.dev.Compiler.run(Compiler.java:167)
    at com.google.gwt.dev.Compiler.run(Compiler.java:132)
    at com.google.gwt.dev.Compiler$1.run(Compiler.java:99)
    at com.google.gwt.dev.CompileTaskRunner.doRun(CompileTaskRunner.java:55)
    at com.google.gwt.dev.CompileTaskRunner.runWithAppropriateLogger(CompileTaskRunner.java:50)
    at com.google.gwt.dev.Compiler.main(Compiler.java:106)

请告诉我这是什么原因,提前谢谢!坦加拉吉

4

2 回答 2

0

不确定 Maven,但尝试删除 2 gwt-unitCache 目录并再次尝试编译

在此处输入图像描述

于 2014-10-09T18:53:10.207 回答
0

我只是有同样的错误,似乎是因为我没有明确添加

<inherits name="com.google.gwt.user.User"/>

到我的 GWT 模块 xml

于 2015-01-20T15:45:30.107 回答