Community
Participate
Working Groups
Build 20020416 From Rodrigo: I've been looking into building Eclipse using javac instead of the JDT compiler and found that the following method from org.eclipse.pde.internal.core.schema.SchemaCompositor does not compile properly. The workaround is to replace this.ALL with ALL and so on. public void write(String indent, PrintWriter writer) { writeComments(writer); String tag = null; switch (kind) { case this.ALL : tag = "all"; break; case this.CHOICE : tag = "choice"; break; case this.GROUP : tag = "group"; break; case this.SEQUENCE : tag = "sequence"; break; } if (tag == null) return; writer.print(indent + "<" + tag); if (getMinOccurs() != 1 && getMaxOccurs() != 1) { String min = "" + getMinOccurs(); String max = getMaxOccurs() == Integer.MAX_VALUE ? "unbounded" : ("" + getMaxOccurs()); writer.print(" minOccurs=\"" + min + "\" maxOccurs=\"" + max + "\""); } writer.println(">"); String indent2 = indent + Schema.INDENT; for (int i = 0; i < children.size(); i++) { Object obj = children.elementAt(i); if (obj instanceof IWritable) { ((IWritable) obj).write(indent2, writer); } } writer.println(indent + "</" + tag + ">"); }
This is a bug in our compiler as per constant expressions specs. Both javac 1.3.1 and javac 1.4 are rejecting this code. Fixed