1.1 --- a/vm/src/main/java/org/apidesign/vm4brwsr/ByteCodeToJavaScript.java Mon Jan 14 09:47:38 2013 +0100
1.2 +++ b/vm/src/main/java/org/apidesign/vm4brwsr/ByteCodeToJavaScript.java Mon Jan 14 13:21:40 2013 +0100
1.3 @@ -491,7 +491,7 @@
1.4 emit(out, "@1 = @2;", lmapper.setD(3), smapper.popD());
1.5 break;
1.6 case opc_iadd:
1.7 - emit(out, "@1 = __add32(@1,@2);", smapper.getI(1), smapper.popI());
1.8 + emit(out, "@1 = @1.add32(@2);", smapper.getI(1), smapper.popI());
1.9 break;
1.10 case opc_ladd:
1.11 emit(out, "@1 += @2;", smapper.getL(1), smapper.popL());
1.12 @@ -503,7 +503,7 @@
1.13 emit(out, "@1 += @2;", smapper.getD(1), smapper.popD());
1.14 break;
1.15 case opc_isub:
1.16 - emit(out, "@1 = __sub32(@1,@2);", smapper.getI(1), smapper.popI());
1.17 + emit(out, "@1 = @1.sub32(@2);", smapper.getI(1), smapper.popI());
1.18 break;
1.19 case opc_lsub:
1.20 emit(out, "@1 -= @2;", smapper.getL(1), smapper.popL());
1.21 @@ -515,7 +515,7 @@
1.22 emit(out, "@1 -= @2;", smapper.getD(1), smapper.popD());
1.23 break;
1.24 case opc_imul:
1.25 - emit(out, "@1 = __mul32(@1,@2);", smapper.getI(1), smapper.popI());
1.26 + emit(out, "@1 = @1.mul32(@2);", smapper.getI(1), smapper.popI());
1.27 break;
1.28 case opc_lmul:
1.29 emit(out, "@1 *= @2;", smapper.getL(1), smapper.popL());
1.30 @@ -672,13 +672,13 @@
1.31 smapper.popD(), smapper.pushL());
1.32 break;
1.33 case opc_i2b:
1.34 - emit(out, "@1 = __toInt8(@1);", smapper.getI(0));
1.35 + emit(out, "@1 = @1.toInt8();", smapper.getI(0));
1.36 break;
1.37 case opc_i2c:
1.38 out.append("{ /* number conversion */ }");
1.39 break;
1.40 case opc_i2s:
1.41 - emit(out, "@1 = __toInt16(@1);", smapper.getI(0));
1.42 + emit(out, "@1 = @1.toInt16();", smapper.getI(0));
1.43 break;
1.44 case opc_aconst_null:
1.45 emit(out, "@1 = null;", smapper.pushA());