vm/src/test/java/org/apidesign/vm4brwsr/Numbers.java
brancharithmetic
changeset 620 189f695d0b02
parent 617 960e219425e2
child 627 4c2b92281cdc
     1.1 --- a/vm/src/test/java/org/apidesign/vm4brwsr/Numbers.java	Thu Jan 31 13:55:12 2013 +0100
     1.2 +++ b/vm/src/test/java/org/apidesign/vm4brwsr/Numbers.java	Thu Jan 31 15:26:09 2013 +0100
     1.3 @@ -80,8 +80,12 @@
     1.4          return (disX.readLong() + disY.readLong());
     1.5      }
     1.6      
     1.7 -    public static long subL(long x, long y) {
     1.8 -        return (x - y);
     1.9 +    public static long subL(byte[] arrX, byte[] arrY) throws IOException {
    1.10 +        ByteArrayInputStream isX = new ByteArrayInputStream(arrX);
    1.11 +        DataInputStream disX = new DataInputStream(isX);
    1.12 +        ByteArrayInputStream isY = new ByteArrayInputStream(arrY);
    1.13 +        DataInputStream disY = new DataInputStream(isY);
    1.14 +        return (disX.readLong() - disY.readLong());
    1.15      }
    1.16      
    1.17      public static long mulL(long x, long y) {