Class ExactMath

java.lang.Object
com.oracle.truffle.api.ExactMath

public class ExactMath extends Object
This class contains methods that will be part of java.lang.Math starting with JDK 8. Until JDK 8 is release, we duplicate them here because they are generally useful for dynamic language implementations.
  • Constructor Details

    • ExactMath

      public ExactMath()
  • Method Details

    • addExact

      public static int addExact(int x, int y)
    • addExact

      public static long addExact(long x, long y)
    • subtractExact

      public static int subtractExact(int x, int y)
    • subtractExact

      public static long subtractExact(long x, long y)
    • multiplyExact

      public static int multiplyExact(int x, int y)
    • multiplyExact

      public static long multiplyExact(long x, long y)
    • multiplyHigh

      public static int multiplyHigh(int x, int y)
    • multiplyHighUnsigned

      public static int multiplyHighUnsigned(int x, int y)
    • multiplyHigh

      public static long multiplyHigh(long x, long y)
    • multiplyHighUnsigned

      public static long multiplyHighUnsigned(long x, long y)