This error was introduced by my recent changes to update the Java source
files to Java5. In this case, auto-boxing created java.lang.Byte instead
of java.lang.Integer. The patch is already applied to trunk, so the
build should work again.
Thanks for reporting the issue!
http://jira.openlaszlo.org/jira/browse/LPP-9846
Yes, can confirm that. I see the same problem.
On Mon, Mar 21, 2011 at 1:51 AM, Donald Anderson<dda at ddanderson.com
<http://www.openlaszlo.org/mailman/listinfo/laszlo-dev>> wrote:
>/ Anyone else seeing a build error in trunk?
/>/ lzl:
/>/ [echo] Compiling
/>/
/Users/clients/laszlo/src/svn/openlaszlo/trunk-f/lps/includes/lfc/lzpreloader.lzl
/>/ [java] Exception compiling scriptfile: java.lang.Byte cannot be cast
to
/>/ java.lang.Integer
/>/ [java] java.lang.ClassCastException: java.lang.Byte cannot be cast to
/>/ java.lang.Integer
/>/ [java] at
/>/
org.openlaszlo.sc.Instructions$DefineFunction2Instruction.writeArgs(Instructions.java:836)
/>/ [java] at
/>/
org.openlaszlo.sc.Instructions$ConcreteInstruction.writeBytes(Instructions.java:376)
/>/ [java] at
/>/ org.openlaszlo.sc.Assembler.resolveTarget(Assembler.java:263)
/>/ [java] at org.openlaszlo.sc.Assembler.emit(Assembler.java:319)
/>/ [java] at org.openlaszlo.sc.Optimizer.emit(Optimizer.java:120)
/>/ [java] at org.openlaszlo.sc.Optimizer.assemble(Optimizer.java:52)
/>/ [java] at org.openlaszlo.sc.Compiler.compile(Compiler.java:412)
/>/ [java] at org.openlaszlo.sc.lzsc.compile(lzsc.java:127)
/>/ [java] at org.openlaszlo.sc.lzsc.compile(lzsc.java:366)
/>/ [java] at org.openlaszlo.sc.Main.main(Main.java:23)
/>/ [java] Compilation aborted.
/>/ Changing Instructions.java line 836 thusly seems to fix it:
/>/ public void writeArgs(ByteBuffer bytes, Map<String, Integer> pool) {
/>/ assert bytes.order() == ByteOrder.LITTLE_ENDIAN;
/>/ try {
/>/ List<Object> args = this.args;
/>/ String fname = (String)args.get(1);
/>/ if (fname == null) fname = "";
/>/ ==> byte nregs = ((Number)args.get(2)).byteValue(); // was
/>/ (Integer) cast
/>/ List<Object> fnargs = args.subList(3, args.size());
/>/ There are other similar casts of elements of args to Integer:
/>/ Instructions.java: lines 419, 432, 653. Don't know if they are similarly
/>/ affected.
/>/ - Don
/>/ --
/>/ Don Anderson
/>/ Java/C/C++, Berkeley DB, systems consultant
/>/
/>/ voice: 617-306-2057
/>/ email:dda at ddanderson.com
<http://www.openlaszlo.org/mailman/listinfo/laszlo-dev>
/>/ www:http://www.ddanderson.com
/>/ blog:http://libdb.wordpress.com
/>/
///