diff -r 271a3038d6ab -r d6f8b4a85fb0 jdk/test/java/lang/invoke/VarHandles/VarHandleTestMethodTypeLong.java --- a/jdk/test/java/lang/invoke/VarHandles/VarHandleTestMethodTypeLong.java Mon Jun 06 16:18:01 2016 -0700 +++ b/jdk/test/java/lang/invoke/VarHandles/VarHandleTestMethodTypeLong.java Wed Jun 15 11:20:15 2016 +0300 @@ -43,13 +43,13 @@ import static java.lang.invoke.MethodType.*; public class VarHandleTestMethodTypeLong extends VarHandleBaseTest { - static final long static_final_v = 1L; + static final long static_final_v = 0x0123456789ABCDEFL; - static long static_v = 1L; + static long static_v = 0x0123456789ABCDEFL; - final long final_v = 1L; + final long final_v = 0x0123456789ABCDEFL; - long v = 1L; + long v = 0x0123456789ABCDEFL; VarHandle vhFinalField; @@ -154,23 +154,23 @@ // Set // Incorrect argument types checkNPE(() -> { // null receiver - vh.set(null, 1L); + vh.set(null, 0x0123456789ABCDEFL); }); checkCCE(() -> { // receiver reference class - vh.set(Void.class, 1L); + vh.set(Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // value reference class vh.set(recv, Void.class); }); checkWMTE(() -> { // receiver primitive class - vh.set(0, 1L); + vh.set(0, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 vh.set(); }); checkWMTE(() -> { // > - vh.set(recv, 1L, Void.class); + vh.set(recv, 0x0123456789ABCDEFL, Void.class); }); @@ -204,23 +204,23 @@ // SetVolatile // Incorrect argument types checkNPE(() -> { // null receiver - vh.setVolatile(null, 1L); + vh.setVolatile(null, 0x0123456789ABCDEFL); }); checkCCE(() -> { // receiver reference class - vh.setVolatile(Void.class, 1L); + vh.setVolatile(Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // value reference class vh.setVolatile(recv, Void.class); }); checkWMTE(() -> { // receiver primitive class - vh.setVolatile(0, 1L); + vh.setVolatile(0, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 vh.setVolatile(); }); checkWMTE(() -> { // > - vh.setVolatile(recv, 1L, Void.class); + vh.setVolatile(recv, 0x0123456789ABCDEFL, Void.class); }); @@ -254,23 +254,23 @@ // SetOpaque // Incorrect argument types checkNPE(() -> { // null receiver - vh.setOpaque(null, 1L); + vh.setOpaque(null, 0x0123456789ABCDEFL); }); checkCCE(() -> { // receiver reference class - vh.setOpaque(Void.class, 1L); + vh.setOpaque(Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // value reference class vh.setOpaque(recv, Void.class); }); checkWMTE(() -> { // receiver primitive class - vh.setOpaque(0, 1L); + vh.setOpaque(0, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 vh.setOpaque(); }); checkWMTE(() -> { // > - vh.setOpaque(recv, 1L, Void.class); + vh.setOpaque(recv, 0x0123456789ABCDEFL, Void.class); }); @@ -304,341 +304,341 @@ // SetRelease // Incorrect argument types checkNPE(() -> { // null receiver - vh.setRelease(null, 1L); + vh.setRelease(null, 0x0123456789ABCDEFL); }); checkCCE(() -> { // receiver reference class - vh.setRelease(Void.class, 1L); + vh.setRelease(Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // value reference class vh.setRelease(recv, Void.class); }); checkWMTE(() -> { // receiver primitive class - vh.setRelease(0, 1L); + vh.setRelease(0, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 vh.setRelease(); }); checkWMTE(() -> { // > - vh.setRelease(recv, 1L, Void.class); + vh.setRelease(recv, 0x0123456789ABCDEFL, Void.class); }); // CompareAndSet // Incorrect argument types checkNPE(() -> { // null receiver - boolean r = vh.compareAndSet(null, 1L, 1L); + boolean r = vh.compareAndSet(null, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkCCE(() -> { // receiver reference class - boolean r = vh.compareAndSet(Void.class, 1L, 1L); + boolean r = vh.compareAndSet(Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // expected reference class - boolean r = vh.compareAndSet(recv, Void.class, 1L); + boolean r = vh.compareAndSet(recv, Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - boolean r = vh.compareAndSet(recv, 1L, Void.class); + boolean r = vh.compareAndSet(recv, 0x0123456789ABCDEFL, Void.class); }); checkWMTE(() -> { // receiver primitive class - boolean r = vh.compareAndSet(0, 1L, 1L); + boolean r = vh.compareAndSet(0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 boolean r = vh.compareAndSet(); }); checkWMTE(() -> { // > - boolean r = vh.compareAndSet(recv, 1L, 1L, Void.class); + boolean r = vh.compareAndSet(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // WeakCompareAndSet // Incorrect argument types checkNPE(() -> { // null receiver - boolean r = vh.weakCompareAndSet(null, 1L, 1L); + boolean r = vh.weakCompareAndSet(null, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkCCE(() -> { // receiver reference class - boolean r = vh.weakCompareAndSet(Void.class, 1L, 1L); + boolean r = vh.weakCompareAndSet(Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // expected reference class - boolean r = vh.weakCompareAndSet(recv, Void.class, 1L); + boolean r = vh.weakCompareAndSet(recv, Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - boolean r = vh.weakCompareAndSet(recv, 1L, Void.class); + boolean r = vh.weakCompareAndSet(recv, 0x0123456789ABCDEFL, Void.class); }); checkWMTE(() -> { // receiver primitive class - boolean r = vh.weakCompareAndSet(0, 1L, 1L); + boolean r = vh.weakCompareAndSet(0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 boolean r = vh.weakCompareAndSet(); }); checkWMTE(() -> { // > - boolean r = vh.weakCompareAndSet(recv, 1L, 1L, Void.class); + boolean r = vh.weakCompareAndSet(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // WeakCompareAndSetVolatile // Incorrect argument types checkNPE(() -> { // null receiver - boolean r = vh.weakCompareAndSetVolatile(null, 1L, 1L); + boolean r = vh.weakCompareAndSetVolatile(null, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkCCE(() -> { // receiver reference class - boolean r = vh.weakCompareAndSetVolatile(Void.class, 1L, 1L); + boolean r = vh.weakCompareAndSetVolatile(Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // expected reference class - boolean r = vh.weakCompareAndSetVolatile(recv, Void.class, 1L); + boolean r = vh.weakCompareAndSetVolatile(recv, Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - boolean r = vh.weakCompareAndSetVolatile(recv, 1L, Void.class); + boolean r = vh.weakCompareAndSetVolatile(recv, 0x0123456789ABCDEFL, Void.class); }); checkWMTE(() -> { // receiver primitive class - boolean r = vh.weakCompareAndSetVolatile(0, 1L, 1L); + boolean r = vh.weakCompareAndSetVolatile(0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 boolean r = vh.weakCompareAndSetVolatile(); }); checkWMTE(() -> { // > - boolean r = vh.weakCompareAndSetVolatile(recv, 1L, 1L, Void.class); + boolean r = vh.weakCompareAndSetVolatile(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // WeakCompareAndSetAcquire // Incorrect argument types checkNPE(() -> { // null receiver - boolean r = vh.weakCompareAndSetAcquire(null, 1L, 1L); + boolean r = vh.weakCompareAndSetAcquire(null, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkCCE(() -> { // receiver reference class - boolean r = vh.weakCompareAndSetAcquire(Void.class, 1L, 1L); + boolean r = vh.weakCompareAndSetAcquire(Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // expected reference class - boolean r = vh.weakCompareAndSetAcquire(recv, Void.class, 1L); + boolean r = vh.weakCompareAndSetAcquire(recv, Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - boolean r = vh.weakCompareAndSetAcquire(recv, 1L, Void.class); + boolean r = vh.weakCompareAndSetAcquire(recv, 0x0123456789ABCDEFL, Void.class); }); checkWMTE(() -> { // receiver primitive class - boolean r = vh.weakCompareAndSetAcquire(0, 1L, 1L); + boolean r = vh.weakCompareAndSetAcquire(0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 boolean r = vh.weakCompareAndSetAcquire(); }); checkWMTE(() -> { // > - boolean r = vh.weakCompareAndSetAcquire(recv, 1L, 1L, Void.class); + boolean r = vh.weakCompareAndSetAcquire(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // WeakCompareAndSetRelease // Incorrect argument types checkNPE(() -> { // null receiver - boolean r = vh.weakCompareAndSetRelease(null, 1L, 1L); + boolean r = vh.weakCompareAndSetRelease(null, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkCCE(() -> { // receiver reference class - boolean r = vh.weakCompareAndSetRelease(Void.class, 1L, 1L); + boolean r = vh.weakCompareAndSetRelease(Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // expected reference class - boolean r = vh.weakCompareAndSetRelease(recv, Void.class, 1L); + boolean r = vh.weakCompareAndSetRelease(recv, Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - boolean r = vh.weakCompareAndSetRelease(recv, 1L, Void.class); + boolean r = vh.weakCompareAndSetRelease(recv, 0x0123456789ABCDEFL, Void.class); }); checkWMTE(() -> { // receiver primitive class - boolean r = vh.weakCompareAndSetRelease(0, 1L, 1L); + boolean r = vh.weakCompareAndSetRelease(0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 boolean r = vh.weakCompareAndSetRelease(); }); checkWMTE(() -> { // > - boolean r = vh.weakCompareAndSetRelease(recv, 1L, 1L, Void.class); + boolean r = vh.weakCompareAndSetRelease(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // CompareAndExchangeVolatile // Incorrect argument types checkNPE(() -> { // null receiver - long x = (long) vh.compareAndExchangeVolatile(null, 1L, 1L); + long x = (long) vh.compareAndExchangeVolatile(null, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkCCE(() -> { // receiver reference class - long x = (long) vh.compareAndExchangeVolatile(Void.class, 1L, 1L); + long x = (long) vh.compareAndExchangeVolatile(Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // expected reference class - long x = (long) vh.compareAndExchangeVolatile(recv, Void.class, 1L); + long x = (long) vh.compareAndExchangeVolatile(recv, Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - long x = (long) vh.compareAndExchangeVolatile(recv, 1L, Void.class); + long x = (long) vh.compareAndExchangeVolatile(recv, 0x0123456789ABCDEFL, Void.class); }); checkWMTE(() -> { // reciever primitive class - long x = (long) vh.compareAndExchangeVolatile(0, 1L, 1L); + long x = (long) vh.compareAndExchangeVolatile(0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect return type checkWMTE(() -> { // reference class - Void r = (Void) vh.compareAndExchangeVolatile(recv, 1L, 1L); + Void r = (Void) vh.compareAndExchangeVolatile(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class - boolean x = (boolean) vh.compareAndExchangeVolatile(recv, 1L, 1L); + boolean x = (boolean) vh.compareAndExchangeVolatile(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 long x = (long) vh.compareAndExchangeVolatile(); }); checkWMTE(() -> { // > - long x = (long) vh.compareAndExchangeVolatile(recv, 1L, 1L, Void.class); + long x = (long) vh.compareAndExchangeVolatile(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // CompareAndExchangeVolatileAcquire // Incorrect argument types checkNPE(() -> { // null receiver - long x = (long) vh.compareAndExchangeAcquire(null, 1L, 1L); + long x = (long) vh.compareAndExchangeAcquire(null, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkCCE(() -> { // receiver reference class - long x = (long) vh.compareAndExchangeAcquire(Void.class, 1L, 1L); + long x = (long) vh.compareAndExchangeAcquire(Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // expected reference class - long x = (long) vh.compareAndExchangeAcquire(recv, Void.class, 1L); + long x = (long) vh.compareAndExchangeAcquire(recv, Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - long x = (long) vh.compareAndExchangeAcquire(recv, 1L, Void.class); + long x = (long) vh.compareAndExchangeAcquire(recv, 0x0123456789ABCDEFL, Void.class); }); checkWMTE(() -> { // reciever primitive class - long x = (long) vh.compareAndExchangeAcquire(0, 1L, 1L); + long x = (long) vh.compareAndExchangeAcquire(0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect return type checkWMTE(() -> { // reference class - Void r = (Void) vh.compareAndExchangeAcquire(recv, 1L, 1L); + Void r = (Void) vh.compareAndExchangeAcquire(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class - boolean x = (boolean) vh.compareAndExchangeAcquire(recv, 1L, 1L); + boolean x = (boolean) vh.compareAndExchangeAcquire(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 long x = (long) vh.compareAndExchangeAcquire(); }); checkWMTE(() -> { // > - long x = (long) vh.compareAndExchangeAcquire(recv, 1L, 1L, Void.class); + long x = (long) vh.compareAndExchangeAcquire(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // CompareAndExchangeRelease // Incorrect argument types checkNPE(() -> { // null receiver - long x = (long) vh.compareAndExchangeRelease(null, 1L, 1L); + long x = (long) vh.compareAndExchangeRelease(null, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkCCE(() -> { // receiver reference class - long x = (long) vh.compareAndExchangeRelease(Void.class, 1L, 1L); + long x = (long) vh.compareAndExchangeRelease(Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // expected reference class - long x = (long) vh.compareAndExchangeRelease(recv, Void.class, 1L); + long x = (long) vh.compareAndExchangeRelease(recv, Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - long x = (long) vh.compareAndExchangeRelease(recv, 1L, Void.class); + long x = (long) vh.compareAndExchangeRelease(recv, 0x0123456789ABCDEFL, Void.class); }); checkWMTE(() -> { // reciever primitive class - long x = (long) vh.compareAndExchangeRelease(0, 1L, 1L); + long x = (long) vh.compareAndExchangeRelease(0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect return type checkWMTE(() -> { // reference class - Void r = (Void) vh.compareAndExchangeRelease(recv, 1L, 1L); + Void r = (Void) vh.compareAndExchangeRelease(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class - boolean x = (boolean) vh.compareAndExchangeRelease(recv, 1L, 1L); + boolean x = (boolean) vh.compareAndExchangeRelease(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 long x = (long) vh.compareAndExchangeRelease(); }); checkWMTE(() -> { // > - long x = (long) vh.compareAndExchangeRelease(recv, 1L, 1L, Void.class); + long x = (long) vh.compareAndExchangeRelease(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // GetAndSet // Incorrect argument types checkNPE(() -> { // null receiver - long x = (long) vh.getAndSet(null, 1L); + long x = (long) vh.getAndSet(null, 0x0123456789ABCDEFL); }); checkCCE(() -> { // receiver reference class - long x = (long) vh.getAndSet(Void.class, 1L); + long x = (long) vh.getAndSet(Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // value reference class long x = (long) vh.getAndSet(recv, Void.class); }); checkWMTE(() -> { // reciever primitive class - long x = (long) vh.getAndSet(0, 1L); + long x = (long) vh.getAndSet(0, 0x0123456789ABCDEFL); }); // Incorrect return type checkWMTE(() -> { // reference class - Void r = (Void) vh.getAndSet(recv, 1L); + Void r = (Void) vh.getAndSet(recv, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class - boolean x = (boolean) vh.getAndSet(recv, 1L); + boolean x = (boolean) vh.getAndSet(recv, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 long x = (long) vh.getAndSet(); }); checkWMTE(() -> { // > - long x = (long) vh.getAndSet(recv, 1L, Void.class); + long x = (long) vh.getAndSet(recv, 0x0123456789ABCDEFL, Void.class); }); // GetAndAdd // Incorrect argument types checkNPE(() -> { // null receiver - long x = (long) vh.getAndAdd(null, 1L); + long x = (long) vh.getAndAdd(null, 0x0123456789ABCDEFL); }); checkCCE(() -> { // receiver reference class - long x = (long) vh.getAndAdd(Void.class, 1L); + long x = (long) vh.getAndAdd(Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // value reference class long x = (long) vh.getAndAdd(recv, Void.class); }); checkWMTE(() -> { // reciever primitive class - long x = (long) vh.getAndAdd(0, 1L); + long x = (long) vh.getAndAdd(0, 0x0123456789ABCDEFL); }); // Incorrect return type checkWMTE(() -> { // reference class - Void r = (Void) vh.getAndAdd(recv, 1L); + Void r = (Void) vh.getAndAdd(recv, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class - boolean x = (boolean) vh.getAndAdd(recv, 1L); + boolean x = (boolean) vh.getAndAdd(recv, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 long x = (long) vh.getAndAdd(); }); checkWMTE(() -> { // > - long x = (long) vh.getAndAdd(recv, 1L, Void.class); + long x = (long) vh.getAndAdd(recv, 0x0123456789ABCDEFL, Void.class); }); // AddAndGet // Incorrect argument types checkNPE(() -> { // null receiver - long x = (long) vh.addAndGet(null, 1L); + long x = (long) vh.addAndGet(null, 0x0123456789ABCDEFL); }); checkCCE(() -> { // receiver reference class - long x = (long) vh.addAndGet(Void.class, 1L); + long x = (long) vh.addAndGet(Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // value reference class long x = (long) vh.addAndGet(recv, Void.class); }); checkWMTE(() -> { // reciever primitive class - long x = (long) vh.addAndGet(0, 1L); + long x = (long) vh.addAndGet(0, 0x0123456789ABCDEFL); }); // Incorrect return type checkWMTE(() -> { // reference class - Void r = (Void) vh.addAndGet(recv, 1L); + Void r = (Void) vh.addAndGet(recv, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class - boolean x = (boolean) vh.addAndGet(recv, 1L); + boolean x = (boolean) vh.addAndGet(recv, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 long x = (long) vh.addAndGet(); }); checkWMTE(() -> { // > - long x = (long) vh.addAndGet(recv, 1L, Void.class); + long x = (long) vh.addAndGet(recv, 0x0123456789ABCDEFL, Void.class); }); } @@ -681,11 +681,11 @@ // Incorrect argument types checkNPE(() -> { // null receiver hs.get(am, methodType(void.class, VarHandleTestMethodTypeLong.class, long.class)). - invokeExact((VarHandleTestMethodTypeLong) null, 1L); + invokeExact((VarHandleTestMethodTypeLong) null, 0x0123456789ABCDEFL); }); hs.checkWMTEOrCCE(() -> { // receiver reference class hs.get(am, methodType(void.class, Class.class, long.class)). - invokeExact(Void.class, 1L); + invokeExact(Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // value reference class hs.get(am, methodType(void.class, VarHandleTestMethodTypeLong.class, Class.class)). @@ -693,7 +693,7 @@ }); checkWMTE(() -> { // receiver primitive class hs.get(am, methodType(void.class, int.class, long.class)). - invokeExact(0, 1L); + invokeExact(0, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 @@ -702,7 +702,7 @@ }); checkWMTE(() -> { // > hs.get(am, methodType(void.class, VarHandleTestMethodTypeLong.class, long.class, Class.class)). - invokeExact(recv, 1L, Void.class); + invokeExact(recv, 0x0123456789ABCDEFL, Void.class); }); } @@ -710,23 +710,23 @@ // Incorrect argument types checkNPE(() -> { // null receiver boolean r = (boolean) hs.get(am, methodType(boolean.class, VarHandleTestMethodTypeLong.class, long.class, long.class)). - invokeExact((VarHandleTestMethodTypeLong) null, 1L, 1L); + invokeExact((VarHandleTestMethodTypeLong) null, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); hs.checkWMTEOrCCE(() -> { // receiver reference class boolean r = (boolean) hs.get(am, methodType(boolean.class, Class.class, long.class, long.class)). - invokeExact(Void.class, 1L, 1L); + invokeExact(Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // expected reference class boolean r = (boolean) hs.get(am, methodType(boolean.class, VarHandleTestMethodTypeLong.class, Class.class, long.class)). - invokeExact(recv, Void.class, 1L); + invokeExact(recv, Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class boolean r = (boolean) hs.get(am, methodType(boolean.class, VarHandleTestMethodTypeLong.class, long.class, Class.class)). - invokeExact(recv, 1L, Void.class); + invokeExact(recv, 0x0123456789ABCDEFL, Void.class); }); checkWMTE(() -> { // receiver primitive class boolean r = (boolean) hs.get(am, methodType(boolean.class, int.class , long.class, long.class)). - invokeExact(0, 1L, 1L); + invokeExact(0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 @@ -735,39 +735,39 @@ }); checkWMTE(() -> { // > boolean r = (boolean) hs.get(am, methodType(boolean.class, VarHandleTestMethodTypeLong.class, long.class, long.class, Class.class)). - invokeExact(recv, 1L, 1L, Void.class); + invokeExact(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); } for (TestAccessMode am : testAccessModesOfType(TestAccessType.COMPARE_AND_EXCHANGE)) { checkNPE(() -> { // null receiver long x = (long) hs.get(am, methodType(long.class, VarHandleTestMethodTypeLong.class, long.class, long.class)). - invokeExact((VarHandleTestMethodTypeLong) null, 1L, 1L); + invokeExact((VarHandleTestMethodTypeLong) null, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); hs.checkWMTEOrCCE(() -> { // receiver reference class long x = (long) hs.get(am, methodType(long.class, Class.class, long.class, long.class)). - invokeExact(Void.class, 1L, 1L); + invokeExact(Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // expected reference class long x = (long) hs.get(am, methodType(long.class, VarHandleTestMethodTypeLong.class, Class.class, long.class)). - invokeExact(recv, Void.class, 1L); + invokeExact(recv, Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class long x = (long) hs.get(am, methodType(long.class, VarHandleTestMethodTypeLong.class, long.class, Class.class)). - invokeExact(recv, 1L, Void.class); + invokeExact(recv, 0x0123456789ABCDEFL, Void.class); }); checkWMTE(() -> { // reciever primitive class long x = (long) hs.get(am, methodType(long.class, int.class , long.class, long.class)). - invokeExact(0, 1L, 1L); + invokeExact(0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect return type checkWMTE(() -> { // reference class Void r = (Void) hs.get(am, methodType(Void.class, VarHandleTestMethodTypeLong.class , long.class, long.class)). - invokeExact(recv, 1L, 1L); + invokeExact(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class boolean x = (boolean) hs.get(am, methodType(boolean.class, VarHandleTestMethodTypeLong.class , long.class, long.class)). - invokeExact(recv, 1L, 1L); + invokeExact(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 @@ -776,18 +776,18 @@ }); checkWMTE(() -> { // > long x = (long) hs.get(am, methodType(long.class, VarHandleTestMethodTypeLong.class, long.class, long.class, Class.class)). - invokeExact(recv, 1L, 1L, Void.class); + invokeExact(recv, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); } for (TestAccessMode am : testAccessModesOfType(TestAccessType.GET_AND_SET)) { checkNPE(() -> { // null receiver long x = (long) hs.get(am, methodType(long.class, VarHandleTestMethodTypeLong.class, long.class)). - invokeExact((VarHandleTestMethodTypeLong) null, 1L); + invokeExact((VarHandleTestMethodTypeLong) null, 0x0123456789ABCDEFL); }); hs.checkWMTEOrCCE(() -> { // receiver reference class long x = (long) hs.get(am, methodType(long.class, Class.class, long.class)). - invokeExact(Void.class, 1L); + invokeExact(Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // value reference class long x = (long) hs.get(am, methodType(long.class, VarHandleTestMethodTypeLong.class, Class.class)). @@ -795,16 +795,16 @@ }); checkWMTE(() -> { // reciever primitive class long x = (long) hs.get(am, methodType(long.class, int.class, long.class)). - invokeExact(0, 1L); + invokeExact(0, 0x0123456789ABCDEFL); }); // Incorrect return type checkWMTE(() -> { // reference class Void r = (Void) hs.get(am, methodType(Void.class, VarHandleTestMethodTypeLong.class, long.class)). - invokeExact(recv, 1L); + invokeExact(recv, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class boolean x = (boolean) hs.get(am, methodType(boolean.class, VarHandleTestMethodTypeLong.class, long.class)). - invokeExact(recv, 1L); + invokeExact(recv, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 @@ -813,18 +813,18 @@ }); checkWMTE(() -> { // > long x = (long) hs.get(am, methodType(long.class, VarHandleTestMethodTypeLong.class, long.class)). - invokeExact(recv, 1L, Void.class); + invokeExact(recv, 0x0123456789ABCDEFL, Void.class); }); } for (TestAccessMode am : testAccessModesOfType(TestAccessType.GET_AND_ADD)) { checkNPE(() -> { // null receiver long x = (long) hs.get(am, methodType(long.class, VarHandleTestMethodTypeLong.class, long.class)). - invokeExact((VarHandleTestMethodTypeLong) null, 1L); + invokeExact((VarHandleTestMethodTypeLong) null, 0x0123456789ABCDEFL); }); hs.checkWMTEOrCCE(() -> { // receiver reference class long x = (long) hs.get(am, methodType(long.class, Class.class, long.class)). - invokeExact(Void.class, 1L); + invokeExact(Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // value reference class long x = (long) hs.get(am, methodType(long.class, VarHandleTestMethodTypeLong.class, Class.class)). @@ -832,16 +832,16 @@ }); checkWMTE(() -> { // reciever primitive class long x = (long) hs.get(am, methodType(long.class, int.class, long.class)). - invokeExact(0, 1L); + invokeExact(0, 0x0123456789ABCDEFL); }); // Incorrect return type checkWMTE(() -> { // reference class Void r = (Void) hs.get(am, methodType(Void.class, VarHandleTestMethodTypeLong.class, long.class)). - invokeExact(recv, 1L); + invokeExact(recv, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class boolean x = (boolean) hs.get(am, methodType(boolean.class, VarHandleTestMethodTypeLong.class, long.class)). - invokeExact(recv, 1L); + invokeExact(recv, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 @@ -850,7 +850,7 @@ }); checkWMTE(() -> { // > long x = (long) hs.get(am, methodType(long.class, VarHandleTestMethodTypeLong.class, long.class)). - invokeExact(recv, 1L, Void.class); + invokeExact(recv, 0x0123456789ABCDEFL, Void.class); }); } } @@ -881,7 +881,7 @@ vh.set(); }); checkWMTE(() -> { // > - vh.set(1L, Void.class); + vh.set(0x0123456789ABCDEFL, Void.class); }); @@ -908,7 +908,7 @@ vh.setVolatile(); }); checkWMTE(() -> { // > - vh.setVolatile(1L, Void.class); + vh.setVolatile(0x0123456789ABCDEFL, Void.class); }); @@ -935,7 +935,7 @@ vh.setOpaque(); }); checkWMTE(() -> { // > - vh.setOpaque(1L, Void.class); + vh.setOpaque(0x0123456789ABCDEFL, Void.class); }); @@ -962,164 +962,164 @@ vh.setRelease(); }); checkWMTE(() -> { // > - vh.setRelease(1L, Void.class); + vh.setRelease(0x0123456789ABCDEFL, Void.class); }); // CompareAndSet // Incorrect argument types checkWMTE(() -> { // expected reference class - boolean r = vh.compareAndSet(Void.class, 1L); + boolean r = vh.compareAndSet(Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - boolean r = vh.compareAndSet(1L, Void.class); + boolean r = vh.compareAndSet(0x0123456789ABCDEFL, Void.class); }); // Incorrect arity checkWMTE(() -> { // 0 boolean r = vh.compareAndSet(); }); checkWMTE(() -> { // > - boolean r = vh.compareAndSet(1L, 1L, Void.class); + boolean r = vh.compareAndSet(0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // WeakCompareAndSet // Incorrect argument types checkWMTE(() -> { // expected reference class - boolean r = vh.weakCompareAndSet(Void.class, 1L); + boolean r = vh.weakCompareAndSet(Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - boolean r = vh.weakCompareAndSet(1L, Void.class); + boolean r = vh.weakCompareAndSet(0x0123456789ABCDEFL, Void.class); }); // Incorrect arity checkWMTE(() -> { // 0 boolean r = vh.weakCompareAndSet(); }); checkWMTE(() -> { // > - boolean r = vh.weakCompareAndSet(1L, 1L, Void.class); + boolean r = vh.weakCompareAndSet(0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // WeakCompareAndSetVolatile // Incorrect argument types checkWMTE(() -> { // expected reference class - boolean r = vh.weakCompareAndSetVolatile(Void.class, 1L); + boolean r = vh.weakCompareAndSetVolatile(Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - boolean r = vh.weakCompareAndSetVolatile(1L, Void.class); + boolean r = vh.weakCompareAndSetVolatile(0x0123456789ABCDEFL, Void.class); }); // Incorrect arity checkWMTE(() -> { // 0 boolean r = vh.weakCompareAndSetVolatile(); }); checkWMTE(() -> { // > - boolean r = vh.weakCompareAndSetVolatile(1L, 1L, Void.class); + boolean r = vh.weakCompareAndSetVolatile(0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // WeakCompareAndSetAcquire // Incorrect argument types checkWMTE(() -> { // expected reference class - boolean r = vh.weakCompareAndSetAcquire(Void.class, 1L); + boolean r = vh.weakCompareAndSetAcquire(Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - boolean r = vh.weakCompareAndSetAcquire(1L, Void.class); + boolean r = vh.weakCompareAndSetAcquire(0x0123456789ABCDEFL, Void.class); }); // Incorrect arity checkWMTE(() -> { // 0 boolean r = vh.weakCompareAndSetAcquire(); }); checkWMTE(() -> { // > - boolean r = vh.weakCompareAndSetAcquire(1L, 1L, Void.class); + boolean r = vh.weakCompareAndSetAcquire(0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // WeakCompareAndSetRelease // Incorrect argument types checkWMTE(() -> { // expected reference class - boolean r = vh.weakCompareAndSetRelease(Void.class, 1L); + boolean r = vh.weakCompareAndSetRelease(Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - boolean r = vh.weakCompareAndSetRelease(1L, Void.class); + boolean r = vh.weakCompareAndSetRelease(0x0123456789ABCDEFL, Void.class); }); // Incorrect arity checkWMTE(() -> { // 0 boolean r = vh.weakCompareAndSetRelease(); }); checkWMTE(() -> { // > - boolean r = vh.weakCompareAndSetRelease(1L, 1L, Void.class); + boolean r = vh.weakCompareAndSetRelease(0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // CompareAndExchangeVolatile // Incorrect argument types checkWMTE(() -> { // expected reference class - long x = (long) vh.compareAndExchangeVolatile(Void.class, 1L); + long x = (long) vh.compareAndExchangeVolatile(Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - long x = (long) vh.compareAndExchangeVolatile(1L, Void.class); + long x = (long) vh.compareAndExchangeVolatile(0x0123456789ABCDEFL, Void.class); }); // Incorrect return type checkWMTE(() -> { // reference class - Void r = (Void) vh.compareAndExchangeVolatile(1L, 1L); + Void r = (Void) vh.compareAndExchangeVolatile(0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class - boolean x = (boolean) vh.compareAndExchangeVolatile(1L, 1L); + boolean x = (boolean) vh.compareAndExchangeVolatile(0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 long x = (long) vh.compareAndExchangeVolatile(); }); checkWMTE(() -> { // > - long x = (long) vh.compareAndExchangeVolatile(1L, 1L, Void.class); + long x = (long) vh.compareAndExchangeVolatile(0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // CompareAndExchangeAcquire // Incorrect argument types checkWMTE(() -> { // expected reference class - long x = (long) vh.compareAndExchangeAcquire(Void.class, 1L); + long x = (long) vh.compareAndExchangeAcquire(Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - long x = (long) vh.compareAndExchangeAcquire(1L, Void.class); + long x = (long) vh.compareAndExchangeAcquire(0x0123456789ABCDEFL, Void.class); }); // Incorrect return type checkWMTE(() -> { // reference class - Void r = (Void) vh.compareAndExchangeAcquire(1L, 1L); + Void r = (Void) vh.compareAndExchangeAcquire(0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class - boolean x = (boolean) vh.compareAndExchangeAcquire(1L, 1L); + boolean x = (boolean) vh.compareAndExchangeAcquire(0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 long x = (long) vh.compareAndExchangeAcquire(); }); checkWMTE(() -> { // > - long x = (long) vh.compareAndExchangeAcquire(1L, 1L, Void.class); + long x = (long) vh.compareAndExchangeAcquire(0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // CompareAndExchangeRelease // Incorrect argument types checkWMTE(() -> { // expected reference class - long x = (long) vh.compareAndExchangeRelease(Void.class, 1L); + long x = (long) vh.compareAndExchangeRelease(Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - long x = (long) vh.compareAndExchangeRelease(1L, Void.class); + long x = (long) vh.compareAndExchangeRelease(0x0123456789ABCDEFL, Void.class); }); // Incorrect return type checkWMTE(() -> { // reference class - Void r = (Void) vh.compareAndExchangeRelease(1L, 1L); + Void r = (Void) vh.compareAndExchangeRelease(0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class - boolean x = (boolean) vh.compareAndExchangeRelease(1L, 1L); + boolean x = (boolean) vh.compareAndExchangeRelease(0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 long x = (long) vh.compareAndExchangeRelease(); }); checkWMTE(() -> { // > - long x = (long) vh.compareAndExchangeRelease(1L, 1L, Void.class); + long x = (long) vh.compareAndExchangeRelease(0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); @@ -1130,17 +1130,17 @@ }); // Incorrect return type checkWMTE(() -> { // reference class - Void r = (Void) vh.getAndSet(1L); + Void r = (Void) vh.getAndSet(0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class - boolean x = (boolean) vh.getAndSet(1L); + boolean x = (boolean) vh.getAndSet(0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 long x = (long) vh.getAndSet(); }); checkWMTE(() -> { // > - long x = (long) vh.getAndSet(1L, Void.class); + long x = (long) vh.getAndSet(0x0123456789ABCDEFL, Void.class); }); // GetAndAdd @@ -1150,17 +1150,17 @@ }); // Incorrect return type checkWMTE(() -> { // reference class - Void r = (Void) vh.getAndAdd(1L); + Void r = (Void) vh.getAndAdd(0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class - boolean x = (boolean) vh.getAndAdd(1L); + boolean x = (boolean) vh.getAndAdd(0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 long x = (long) vh.getAndAdd(); }); checkWMTE(() -> { // > - long x = (long) vh.getAndAdd(1L, Void.class); + long x = (long) vh.getAndAdd(0x0123456789ABCDEFL, Void.class); }); @@ -1171,17 +1171,17 @@ }); // Incorrect return type checkWMTE(() -> { // reference class - Void r = (Void) vh.addAndGet(1L); + Void r = (Void) vh.addAndGet(0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class - boolean x = (boolean) vh.addAndGet(1L); + boolean x = (boolean) vh.addAndGet(0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 long x = (long) vh.addAndGet(); }); checkWMTE(() -> { // > - long x = (long) vh.addAndGet(1L, Void.class); + long x = (long) vh.addAndGet(0x0123456789ABCDEFL, Void.class); }); } @@ -1217,18 +1217,18 @@ }); checkWMTE(() -> { // > hs.get(am, methodType(void.class, long.class, Class.class)). - invokeExact(1L, Void.class); + invokeExact(0x0123456789ABCDEFL, Void.class); }); } for (TestAccessMode am : testAccessModesOfType(TestAccessType.COMPARE_AND_SET)) { // Incorrect argument types checkWMTE(() -> { // expected reference class boolean r = (boolean) hs.get(am, methodType(boolean.class, Class.class, long.class)). - invokeExact(Void.class, 1L); + invokeExact(Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class boolean r = (boolean) hs.get(am, methodType(boolean.class, long.class, Class.class)). - invokeExact(1L, Void.class); + invokeExact(0x0123456789ABCDEFL, Void.class); }); // Incorrect arity checkWMTE(() -> { // 0 @@ -1237,7 +1237,7 @@ }); checkWMTE(() -> { // > boolean r = (boolean) hs.get(am, methodType(boolean.class, long.class, long.class, Class.class)). - invokeExact(1L, 1L, Void.class); + invokeExact(0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); } @@ -1245,20 +1245,20 @@ // Incorrect argument types checkWMTE(() -> { // expected reference class long x = (long) hs.get(am, methodType(long.class, Class.class, long.class)). - invokeExact(Void.class, 1L); + invokeExact(Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class long x = (long) hs.get(am, methodType(long.class, long.class, Class.class)). - invokeExact(1L, Void.class); + invokeExact(0x0123456789ABCDEFL, Void.class); }); // Incorrect return type checkWMTE(() -> { // reference class Void r = (Void) hs.get(am, methodType(Void.class, long.class, long.class)). - invokeExact(1L, 1L); + invokeExact(0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class boolean x = (boolean) hs.get(am, methodType(boolean.class, long.class, long.class)). - invokeExact(1L, 1L); + invokeExact(0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 @@ -1267,7 +1267,7 @@ }); checkWMTE(() -> { // > long x = (long) hs.get(am, methodType(long.class, long.class, long.class, Class.class)). - invokeExact(1L, 1L, Void.class); + invokeExact(0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); } @@ -1280,11 +1280,11 @@ // Incorrect return type checkWMTE(() -> { // reference class Void r = (Void) hs.get(am, methodType(Void.class, long.class)). - invokeExact(1L); + invokeExact(0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class boolean x = (boolean) hs.get(am, methodType(boolean.class, long.class)). - invokeExact(1L); + invokeExact(0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 @@ -1293,7 +1293,7 @@ }); checkWMTE(() -> { // > long x = (long) hs.get(am, methodType(long.class, long.class, Class.class)). - invokeExact(1L, Void.class); + invokeExact(0x0123456789ABCDEFL, Void.class); }); } @@ -1306,11 +1306,11 @@ // Incorrect return type checkWMTE(() -> { // reference class Void r = (Void) hs.get(am, methodType(Void.class, long.class)). - invokeExact(1L); + invokeExact(0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class boolean x = (boolean) hs.get(am, methodType(boolean.class, long.class)). - invokeExact(1L); + invokeExact(0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 @@ -1319,7 +1319,7 @@ }); checkWMTE(() -> { // > long x = (long) hs.get(am, methodType(long.class, long.class, Class.class)). - invokeExact(1L, Void.class); + invokeExact(0x0123456789ABCDEFL, Void.class); }); } } @@ -1327,7 +1327,7 @@ static void testArrayWrongMethodType(VarHandle vh) throws Throwable { long[] array = new long[10]; - Arrays.fill(array, 1L); + Arrays.fill(array, 0x0123456789ABCDEFL); // Get // Incorrect argument types @@ -1362,26 +1362,26 @@ // Set // Incorrect argument types checkNPE(() -> { // null array - vh.set(null, 0, 1L); + vh.set(null, 0, 0x0123456789ABCDEFL); }); checkCCE(() -> { // array reference class - vh.set(Void.class, 0, 1L); + vh.set(Void.class, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // value reference class vh.set(array, 0, Void.class); }); checkWMTE(() -> { // receiver primitive class - vh.set(0, 0, 1L); + vh.set(0, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // index reference class - vh.set(array, Void.class, 1L); + vh.set(array, Void.class, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 vh.set(); }); checkWMTE(() -> { // > - vh.set(array, 0, 1L, Void.class); + vh.set(array, 0, 0x0123456789ABCDEFL, Void.class); }); @@ -1418,26 +1418,26 @@ // SetVolatile // Incorrect argument types checkNPE(() -> { // null array - vh.setVolatile(null, 0, 1L); + vh.setVolatile(null, 0, 0x0123456789ABCDEFL); }); checkCCE(() -> { // array reference class - vh.setVolatile(Void.class, 0, 1L); + vh.setVolatile(Void.class, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // value reference class vh.setVolatile(array, 0, Void.class); }); checkWMTE(() -> { // receiver primitive class - vh.setVolatile(0, 0, 1L); + vh.setVolatile(0, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // index reference class - vh.setVolatile(array, Void.class, 1L); + vh.setVolatile(array, Void.class, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 vh.setVolatile(); }); checkWMTE(() -> { // > - vh.setVolatile(array, 0, 1L, Void.class); + vh.setVolatile(array, 0, 0x0123456789ABCDEFL, Void.class); }); @@ -1474,26 +1474,26 @@ // SetOpaque // Incorrect argument types checkNPE(() -> { // null array - vh.setOpaque(null, 0, 1L); + vh.setOpaque(null, 0, 0x0123456789ABCDEFL); }); checkCCE(() -> { // array reference class - vh.setOpaque(Void.class, 0, 1L); + vh.setOpaque(Void.class, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // value reference class vh.setOpaque(array, 0, Void.class); }); checkWMTE(() -> { // receiver primitive class - vh.setOpaque(0, 0, 1L); + vh.setOpaque(0, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // index reference class - vh.setOpaque(array, Void.class, 1L); + vh.setOpaque(array, Void.class, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 vh.setOpaque(); }); checkWMTE(() -> { // > - vh.setOpaque(array, 0, 1L, Void.class); + vh.setOpaque(array, 0, 0x0123456789ABCDEFL, Void.class); }); @@ -1530,383 +1530,383 @@ // SetRelease // Incorrect argument types checkNPE(() -> { // null array - vh.setRelease(null, 0, 1L); + vh.setRelease(null, 0, 0x0123456789ABCDEFL); }); checkCCE(() -> { // array reference class - vh.setRelease(Void.class, 0, 1L); + vh.setRelease(Void.class, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // value reference class vh.setRelease(array, 0, Void.class); }); checkWMTE(() -> { // receiver primitive class - vh.setRelease(0, 0, 1L); + vh.setRelease(0, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // index reference class - vh.setRelease(array, Void.class, 1L); + vh.setRelease(array, Void.class, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 vh.setRelease(); }); checkWMTE(() -> { // > - vh.setRelease(array, 0, 1L, Void.class); + vh.setRelease(array, 0, 0x0123456789ABCDEFL, Void.class); }); // CompareAndSet // Incorrect argument types checkNPE(() -> { // null receiver - boolean r = vh.compareAndSet(null, 0, 1L, 1L); + boolean r = vh.compareAndSet(null, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkCCE(() -> { // receiver reference class - boolean r = vh.compareAndSet(Void.class, 0, 1L, 1L); + boolean r = vh.compareAndSet(Void.class, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // expected reference class - boolean r = vh.compareAndSet(array, 0, Void.class, 1L); + boolean r = vh.compareAndSet(array, 0, Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - boolean r = vh.compareAndSet(array, 0, 1L, Void.class); + boolean r = vh.compareAndSet(array, 0, 0x0123456789ABCDEFL, Void.class); }); checkWMTE(() -> { // receiver primitive class - boolean r = vh.compareAndSet(0, 0, 1L, 1L); + boolean r = vh.compareAndSet(0, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // index reference class - boolean r = vh.compareAndSet(array, Void.class, 1L, 1L); + boolean r = vh.compareAndSet(array, Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 boolean r = vh.compareAndSet(); }); checkWMTE(() -> { // > - boolean r = vh.compareAndSet(array, 0, 1L, 1L, Void.class); + boolean r = vh.compareAndSet(array, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // WeakCompareAndSet // Incorrect argument types checkNPE(() -> { // null receiver - boolean r = vh.weakCompareAndSet(null, 0, 1L, 1L); + boolean r = vh.weakCompareAndSet(null, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkCCE(() -> { // receiver reference class - boolean r = vh.weakCompareAndSet(Void.class, 0, 1L, 1L); + boolean r = vh.weakCompareAndSet(Void.class, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // expected reference class - boolean r = vh.weakCompareAndSet(array, 0, Void.class, 1L); + boolean r = vh.weakCompareAndSet(array, 0, Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - boolean r = vh.weakCompareAndSet(array, 0, 1L, Void.class); + boolean r = vh.weakCompareAndSet(array, 0, 0x0123456789ABCDEFL, Void.class); }); checkWMTE(() -> { // receiver primitive class - boolean r = vh.weakCompareAndSet(0, 0, 1L, 1L); + boolean r = vh.weakCompareAndSet(0, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // index reference class - boolean r = vh.weakCompareAndSet(array, Void.class, 1L, 1L); + boolean r = vh.weakCompareAndSet(array, Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 boolean r = vh.weakCompareAndSet(); }); checkWMTE(() -> { // > - boolean r = vh.weakCompareAndSet(array, 0, 1L, 1L, Void.class); + boolean r = vh.weakCompareAndSet(array, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // WeakCompareAndSetVolatile // Incorrect argument types checkNPE(() -> { // null receiver - boolean r = vh.weakCompareAndSetVolatile(null, 0, 1L, 1L); + boolean r = vh.weakCompareAndSetVolatile(null, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkCCE(() -> { // receiver reference class - boolean r = vh.weakCompareAndSetVolatile(Void.class, 0, 1L, 1L); + boolean r = vh.weakCompareAndSetVolatile(Void.class, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // expected reference class - boolean r = vh.weakCompareAndSetVolatile(array, 0, Void.class, 1L); + boolean r = vh.weakCompareAndSetVolatile(array, 0, Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - boolean r = vh.weakCompareAndSetVolatile(array, 0, 1L, Void.class); + boolean r = vh.weakCompareAndSetVolatile(array, 0, 0x0123456789ABCDEFL, Void.class); }); checkWMTE(() -> { // receiver primitive class - boolean r = vh.weakCompareAndSetVolatile(0, 0, 1L, 1L); + boolean r = vh.weakCompareAndSetVolatile(0, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // index reference class - boolean r = vh.weakCompareAndSetVolatile(array, Void.class, 1L, 1L); + boolean r = vh.weakCompareAndSetVolatile(array, Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 boolean r = vh.weakCompareAndSetVolatile(); }); checkWMTE(() -> { // > - boolean r = vh.weakCompareAndSetVolatile(array, 0, 1L, 1L, Void.class); + boolean r = vh.weakCompareAndSetVolatile(array, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // WeakCompareAndSetAcquire // Incorrect argument types checkNPE(() -> { // null receiver - boolean r = vh.weakCompareAndSetAcquire(null, 0, 1L, 1L); + boolean r = vh.weakCompareAndSetAcquire(null, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkCCE(() -> { // receiver reference class - boolean r = vh.weakCompareAndSetAcquire(Void.class, 0, 1L, 1L); + boolean r = vh.weakCompareAndSetAcquire(Void.class, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // expected reference class - boolean r = vh.weakCompareAndSetAcquire(array, 0, Void.class, 1L); + boolean r = vh.weakCompareAndSetAcquire(array, 0, Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - boolean r = vh.weakCompareAndSetAcquire(array, 0, 1L, Void.class); + boolean r = vh.weakCompareAndSetAcquire(array, 0, 0x0123456789ABCDEFL, Void.class); }); checkWMTE(() -> { // receiver primitive class - boolean r = vh.weakCompareAndSetAcquire(0, 0, 1L, 1L); + boolean r = vh.weakCompareAndSetAcquire(0, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // index reference class - boolean r = vh.weakCompareAndSetAcquire(array, Void.class, 1L, 1L); + boolean r = vh.weakCompareAndSetAcquire(array, Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 boolean r = vh.weakCompareAndSetAcquire(); }); checkWMTE(() -> { // > - boolean r = vh.weakCompareAndSetAcquire(array, 0, 1L, 1L, Void.class); + boolean r = vh.weakCompareAndSetAcquire(array, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // WeakCompareAndSetRelease // Incorrect argument types checkNPE(() -> { // null receiver - boolean r = vh.weakCompareAndSetRelease(null, 0, 1L, 1L); + boolean r = vh.weakCompareAndSetRelease(null, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkCCE(() -> { // receiver reference class - boolean r = vh.weakCompareAndSetRelease(Void.class, 0, 1L, 1L); + boolean r = vh.weakCompareAndSetRelease(Void.class, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // expected reference class - boolean r = vh.weakCompareAndSetRelease(array, 0, Void.class, 1L); + boolean r = vh.weakCompareAndSetRelease(array, 0, Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - boolean r = vh.weakCompareAndSetRelease(array, 0, 1L, Void.class); + boolean r = vh.weakCompareAndSetRelease(array, 0, 0x0123456789ABCDEFL, Void.class); }); checkWMTE(() -> { // receiver primitive class - boolean r = vh.weakCompareAndSetRelease(0, 0, 1L, 1L); + boolean r = vh.weakCompareAndSetRelease(0, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // index reference class - boolean r = vh.weakCompareAndSetRelease(array, Void.class, 1L, 1L); + boolean r = vh.weakCompareAndSetRelease(array, Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 boolean r = vh.weakCompareAndSetRelease(); }); checkWMTE(() -> { // > - boolean r = vh.weakCompareAndSetRelease(array, 0, 1L, 1L, Void.class); + boolean r = vh.weakCompareAndSetRelease(array, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // CompareAndExchangeVolatile // Incorrect argument types checkNPE(() -> { // null receiver - long x = (long) vh.compareAndExchangeVolatile(null, 0, 1L, 1L); + long x = (long) vh.compareAndExchangeVolatile(null, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkCCE(() -> { // array reference class - long x = (long) vh.compareAndExchangeVolatile(Void.class, 0, 1L, 1L); + long x = (long) vh.compareAndExchangeVolatile(Void.class, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // expected reference class - long x = (long) vh.compareAndExchangeVolatile(array, 0, Void.class, 1L); + long x = (long) vh.compareAndExchangeVolatile(array, 0, Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - long x = (long) vh.compareAndExchangeVolatile(array, 0, 1L, Void.class); + long x = (long) vh.compareAndExchangeVolatile(array, 0, 0x0123456789ABCDEFL, Void.class); }); checkWMTE(() -> { // array primitive class - long x = (long) vh.compareAndExchangeVolatile(0, 0, 1L, 1L); + long x = (long) vh.compareAndExchangeVolatile(0, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // index reference class - long x = (long) vh.compareAndExchangeVolatile(array, Void.class, 1L, 1L); + long x = (long) vh.compareAndExchangeVolatile(array, Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect return type checkWMTE(() -> { // reference class - Void r = (Void) vh.compareAndExchangeVolatile(array, 0, 1L, 1L); + Void r = (Void) vh.compareAndExchangeVolatile(array, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class - boolean x = (boolean) vh.compareAndExchangeVolatile(array, 0, 1L, 1L); + boolean x = (boolean) vh.compareAndExchangeVolatile(array, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 long x = (long) vh.compareAndExchangeVolatile(); }); checkWMTE(() -> { // > - long x = (long) vh.compareAndExchangeVolatile(array, 0, 1L, 1L, Void.class); + long x = (long) vh.compareAndExchangeVolatile(array, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // CompareAndExchangeAcquire // Incorrect argument types checkNPE(() -> { // null receiver - long x = (long) vh.compareAndExchangeAcquire(null, 0, 1L, 1L); + long x = (long) vh.compareAndExchangeAcquire(null, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkCCE(() -> { // array reference class - long x = (long) vh.compareAndExchangeAcquire(Void.class, 0, 1L, 1L); + long x = (long) vh.compareAndExchangeAcquire(Void.class, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // expected reference class - long x = (long) vh.compareAndExchangeAcquire(array, 0, Void.class, 1L); + long x = (long) vh.compareAndExchangeAcquire(array, 0, Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - long x = (long) vh.compareAndExchangeAcquire(array, 0, 1L, Void.class); + long x = (long) vh.compareAndExchangeAcquire(array, 0, 0x0123456789ABCDEFL, Void.class); }); checkWMTE(() -> { // array primitive class - long x = (long) vh.compareAndExchangeAcquire(0, 0, 1L, 1L); + long x = (long) vh.compareAndExchangeAcquire(0, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // index reference class - long x = (long) vh.compareAndExchangeAcquire(array, Void.class, 1L, 1L); + long x = (long) vh.compareAndExchangeAcquire(array, Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect return type checkWMTE(() -> { // reference class - Void r = (Void) vh.compareAndExchangeAcquire(array, 0, 1L, 1L); + Void r = (Void) vh.compareAndExchangeAcquire(array, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class - boolean x = (boolean) vh.compareAndExchangeAcquire(array, 0, 1L, 1L); + boolean x = (boolean) vh.compareAndExchangeAcquire(array, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 long x = (long) vh.compareAndExchangeAcquire(); }); checkWMTE(() -> { // > - long x = (long) vh.compareAndExchangeAcquire(array, 0, 1L, 1L, Void.class); + long x = (long) vh.compareAndExchangeAcquire(array, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // CompareAndExchangeRelease // Incorrect argument types checkNPE(() -> { // null receiver - long x = (long) vh.compareAndExchangeRelease(null, 0, 1L, 1L); + long x = (long) vh.compareAndExchangeRelease(null, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkCCE(() -> { // array reference class - long x = (long) vh.compareAndExchangeRelease(Void.class, 0, 1L, 1L); + long x = (long) vh.compareAndExchangeRelease(Void.class, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // expected reference class - long x = (long) vh.compareAndExchangeRelease(array, 0, Void.class, 1L); + long x = (long) vh.compareAndExchangeRelease(array, 0, Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class - long x = (long) vh.compareAndExchangeRelease(array, 0, 1L, Void.class); + long x = (long) vh.compareAndExchangeRelease(array, 0, 0x0123456789ABCDEFL, Void.class); }); checkWMTE(() -> { // array primitive class - long x = (long) vh.compareAndExchangeRelease(0, 0, 1L, 1L); + long x = (long) vh.compareAndExchangeRelease(0, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // index reference class - long x = (long) vh.compareAndExchangeRelease(array, Void.class, 1L, 1L); + long x = (long) vh.compareAndExchangeRelease(array, Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect return type checkWMTE(() -> { // reference class - Void r = (Void) vh.compareAndExchangeRelease(array, 0, 1L, 1L); + Void r = (Void) vh.compareAndExchangeRelease(array, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class - boolean x = (boolean) vh.compareAndExchangeRelease(array, 0, 1L, 1L); + boolean x = (boolean) vh.compareAndExchangeRelease(array, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 long x = (long) vh.compareAndExchangeRelease(); }); checkWMTE(() -> { // > - long x = (long) vh.compareAndExchangeRelease(array, 0, 1L, 1L, Void.class); + long x = (long) vh.compareAndExchangeRelease(array, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); // GetAndSet // Incorrect argument types checkNPE(() -> { // null array - long x = (long) vh.getAndSet(null, 0, 1L); + long x = (long) vh.getAndSet(null, 0, 0x0123456789ABCDEFL); }); checkCCE(() -> { // array reference class - long x = (long) vh.getAndSet(Void.class, 0, 1L); + long x = (long) vh.getAndSet(Void.class, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // value reference class long x = (long) vh.getAndSet(array, 0, Void.class); }); checkWMTE(() -> { // reciarrayever primitive class - long x = (long) vh.getAndSet(0, 0, 1L); + long x = (long) vh.getAndSet(0, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // index reference class - long x = (long) vh.getAndSet(array, Void.class, 1L); + long x = (long) vh.getAndSet(array, Void.class, 0x0123456789ABCDEFL); }); // Incorrect return type checkWMTE(() -> { // reference class - Void r = (Void) vh.getAndSet(array, 0, 1L); + Void r = (Void) vh.getAndSet(array, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class - boolean x = (boolean) vh.getAndSet(array, 0, 1L); + boolean x = (boolean) vh.getAndSet(array, 0, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 long x = (long) vh.getAndSet(); }); checkWMTE(() -> { // > - long x = (long) vh.getAndSet(array, 0, 1L, Void.class); + long x = (long) vh.getAndSet(array, 0, 0x0123456789ABCDEFL, Void.class); }); // GetAndAdd // Incorrect argument types checkNPE(() -> { // null array - long x = (long) vh.getAndAdd(null, 0, 1L); + long x = (long) vh.getAndAdd(null, 0, 0x0123456789ABCDEFL); }); checkCCE(() -> { // array reference class - long x = (long) vh.getAndAdd(Void.class, 0, 1L); + long x = (long) vh.getAndAdd(Void.class, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // value reference class long x = (long) vh.getAndAdd(array, 0, Void.class); }); checkWMTE(() -> { // array primitive class - long x = (long) vh.getAndAdd(0, 0, 1L); + long x = (long) vh.getAndAdd(0, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // index reference class - long x = (long) vh.getAndAdd(array, Void.class, 1L); + long x = (long) vh.getAndAdd(array, Void.class, 0x0123456789ABCDEFL); }); // Incorrect return type checkWMTE(() -> { // reference class - Void r = (Void) vh.getAndAdd(array, 0, 1L); + Void r = (Void) vh.getAndAdd(array, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class - boolean x = (boolean) vh.getAndAdd(array, 0, 1L); + boolean x = (boolean) vh.getAndAdd(array, 0, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 long x = (long) vh.getAndAdd(); }); checkWMTE(() -> { // > - long x = (long) vh.getAndAdd(array, 0, 1L, Void.class); + long x = (long) vh.getAndAdd(array, 0, 0x0123456789ABCDEFL, Void.class); }); // AddAndGet // Incorrect argument types checkNPE(() -> { // null array - long x = (long) vh.addAndGet(null, 0, 1L); + long x = (long) vh.addAndGet(null, 0, 0x0123456789ABCDEFL); }); checkCCE(() -> { // array reference class - long x = (long) vh.addAndGet(Void.class, 0, 1L); + long x = (long) vh.addAndGet(Void.class, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // value reference class long x = (long) vh.addAndGet(array, 0, Void.class); }); checkWMTE(() -> { // array primitive class - long x = (long) vh.addAndGet(0, 0, 1L); + long x = (long) vh.addAndGet(0, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // index reference class - long x = (long) vh.addAndGet(array, Void.class, 1L); + long x = (long) vh.addAndGet(array, Void.class, 0x0123456789ABCDEFL); }); // Incorrect return type checkWMTE(() -> { // reference class - Void r = (Void) vh.addAndGet(array, 0, 1L); + Void r = (Void) vh.addAndGet(array, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class - boolean x = (boolean) vh.addAndGet(array, 0, 1L); + boolean x = (boolean) vh.addAndGet(array, 0, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 long x = (long) vh.addAndGet(); }); checkWMTE(() -> { // > - long x = (long) vh.addAndGet(array, 0, 1L, Void.class); + long x = (long) vh.addAndGet(array, 0, 0x0123456789ABCDEFL, Void.class); }); } static void testArrayWrongMethodType(Handles hs) throws Throwable { long[] array = new long[10]; - Arrays.fill(array, 1L); + Arrays.fill(array, 0x0123456789ABCDEFL); for (TestAccessMode am : testAccessModesOfType(TestAccessType.GET)) { // Incorrect argument types @@ -1950,11 +1950,11 @@ // Incorrect argument types checkNPE(() -> { // null array hs.get(am, methodType(void.class, long[].class, int.class, long.class)). - invokeExact((long[]) null, 0, 1L); + invokeExact((long[]) null, 0, 0x0123456789ABCDEFL); }); hs.checkWMTEOrCCE(() -> { // array reference class hs.get(am, methodType(void.class, Class.class, int.class, long.class)). - invokeExact(Void.class, 0, 1L); + invokeExact(Void.class, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // value reference class hs.get(am, methodType(void.class, long[].class, int.class, Class.class)). @@ -1962,11 +1962,11 @@ }); checkWMTE(() -> { // receiver primitive class hs.get(am, methodType(void.class, int.class, int.class, long.class)). - invokeExact(0, 0, 1L); + invokeExact(0, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // index reference class hs.get(am, methodType(void.class, long[].class, Class.class, long.class)). - invokeExact(array, Void.class, 1L); + invokeExact(array, Void.class, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 @@ -1975,34 +1975,34 @@ }); checkWMTE(() -> { // > hs.get(am, methodType(void.class, long[].class, int.class, Class.class)). - invokeExact(array, 0, 1L, Void.class); + invokeExact(array, 0, 0x0123456789ABCDEFL, Void.class); }); } for (TestAccessMode am : testAccessModesOfType(TestAccessType.COMPARE_AND_SET)) { // Incorrect argument types checkNPE(() -> { // null receiver boolean r = (boolean) hs.get(am, methodType(boolean.class, long[].class, int.class, long.class, long.class)). - invokeExact((long[]) null, 0, 1L, 1L); + invokeExact((long[]) null, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); hs.checkWMTEOrCCE(() -> { // receiver reference class boolean r = (boolean) hs.get(am, methodType(boolean.class, Class.class, int.class, long.class, long.class)). - invokeExact(Void.class, 0, 1L, 1L); + invokeExact(Void.class, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // expected reference class boolean r = (boolean) hs.get(am, methodType(boolean.class, long[].class, int.class, Class.class, long.class)). - invokeExact(array, 0, Void.class, 1L); + invokeExact(array, 0, Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class boolean r = (boolean) hs.get(am, methodType(boolean.class, long[].class, int.class, long.class, Class.class)). - invokeExact(array, 0, 1L, Void.class); + invokeExact(array, 0, 0x0123456789ABCDEFL, Void.class); }); checkWMTE(() -> { // receiver primitive class boolean r = (boolean) hs.get(am, methodType(boolean.class, int.class, int.class, long.class, long.class)). - invokeExact(0, 0, 1L, 1L); + invokeExact(0, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // index reference class boolean r = (boolean) hs.get(am, methodType(boolean.class, long[].class, Class.class, long.class, long.class)). - invokeExact(array, Void.class, 1L, 1L); + invokeExact(array, Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 @@ -2011,7 +2011,7 @@ }); checkWMTE(() -> { // > boolean r = (boolean) hs.get(am, methodType(boolean.class, long[].class, int.class, long.class, long.class, Class.class)). - invokeExact(array, 0, 1L, 1L, Void.class); + invokeExact(array, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); } @@ -2019,36 +2019,36 @@ // Incorrect argument types checkNPE(() -> { // null receiver long x = (long) hs.get(am, methodType(long.class, long[].class, int.class, long.class, long.class)). - invokeExact((long[]) null, 0, 1L, 1L); + invokeExact((long[]) null, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); hs.checkWMTEOrCCE(() -> { // array reference class long x = (long) hs.get(am, methodType(long.class, Class.class, int.class, long.class, long.class)). - invokeExact(Void.class, 0, 1L, 1L); + invokeExact(Void.class, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // expected reference class long x = (long) hs.get(am, methodType(long.class, long[].class, int.class, Class.class, long.class)). - invokeExact(array, 0, Void.class, 1L); + invokeExact(array, 0, Void.class, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // actual reference class long x = (long) hs.get(am, methodType(long.class, long[].class, int.class, long.class, Class.class)). - invokeExact(array, 0, 1L, Void.class); + invokeExact(array, 0, 0x0123456789ABCDEFL, Void.class); }); checkWMTE(() -> { // array primitive class long x = (long) hs.get(am, methodType(long.class, int.class, int.class, long.class, long.class)). - invokeExact(0, 0, 1L, 1L); + invokeExact(0, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // index reference class long x = (long) hs.get(am, methodType(long.class, long[].class, Class.class, long.class, long.class)). - invokeExact(array, Void.class, 1L, 1L); + invokeExact(array, Void.class, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect return type checkWMTE(() -> { // reference class Void r = (Void) hs.get(am, methodType(Void.class, long[].class, int.class, long.class, long.class)). - invokeExact(array, 0, 1L, 1L); + invokeExact(array, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class boolean x = (boolean) hs.get(am, methodType(boolean.class, long[].class, int.class, long.class, long.class)). - invokeExact(array, 0, 1L, 1L); + invokeExact(array, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 @@ -2057,7 +2057,7 @@ }); checkWMTE(() -> { // > long x = (long) hs.get(am, methodType(long.class, long[].class, int.class, long.class, long.class, Class.class)). - invokeExact(array, 0, 1L, 1L, Void.class); + invokeExact(array, 0, 0x0123456789ABCDEFL, 0x0123456789ABCDEFL, Void.class); }); } @@ -2065,11 +2065,11 @@ // Incorrect argument types checkNPE(() -> { // null array long x = (long) hs.get(am, methodType(long.class, long[].class, int.class, long.class)). - invokeExact((long[]) null, 0, 1L); + invokeExact((long[]) null, 0, 0x0123456789ABCDEFL); }); hs.checkWMTEOrCCE(() -> { // array reference class long x = (long) hs.get(am, methodType(long.class, Class.class, int.class, long.class)). - invokeExact(Void.class, 0, 1L); + invokeExact(Void.class, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // value reference class long x = (long) hs.get(am, methodType(long.class, long[].class, int.class, Class.class)). @@ -2077,20 +2077,20 @@ }); checkWMTE(() -> { // array primitive class long x = (long) hs.get(am, methodType(long.class, int.class, int.class, long.class)). - invokeExact(0, 0, 1L); + invokeExact(0, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // index reference class long x = (long) hs.get(am, methodType(long.class, long[].class, Class.class, long.class)). - invokeExact(array, Void.class, 1L); + invokeExact(array, Void.class, 0x0123456789ABCDEFL); }); // Incorrect return type checkWMTE(() -> { // reference class Void r = (Void) hs.get(am, methodType(Void.class, long[].class, int.class, long.class)). - invokeExact(array, 0, 1L); + invokeExact(array, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class boolean x = (boolean) hs.get(am, methodType(boolean.class, long[].class, int.class, long.class)). - invokeExact(array, 0, 1L); + invokeExact(array, 0, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 @@ -2099,7 +2099,7 @@ }); checkWMTE(() -> { // > long x = (long) hs.get(am, methodType(long.class, long[].class, int.class, long.class, Class.class)). - invokeExact(array, 0, 1L, Void.class); + invokeExact(array, 0, 0x0123456789ABCDEFL, Void.class); }); } @@ -2107,11 +2107,11 @@ // Incorrect argument types checkNPE(() -> { // null array long x = (long) hs.get(am, methodType(long.class, long[].class, int.class, long.class)). - invokeExact((long[]) null, 0, 1L); + invokeExact((long[]) null, 0, 0x0123456789ABCDEFL); }); hs.checkWMTEOrCCE(() -> { // array reference class long x = (long) hs.get(am, methodType(long.class, Class.class, int.class, long.class)). - invokeExact(Void.class, 0, 1L); + invokeExact(Void.class, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // value reference class long x = (long) hs.get(am, methodType(long.class, long[].class, int.class, Class.class)). @@ -2119,20 +2119,20 @@ }); checkWMTE(() -> { // array primitive class long x = (long) hs.get(am, methodType(long.class, int.class, int.class, long.class)). - invokeExact(0, 0, 1L); + invokeExact(0, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // index reference class long x = (long) hs.get(am, methodType(long.class, long[].class, Class.class, long.class)). - invokeExact(array, Void.class, 1L); + invokeExact(array, Void.class, 0x0123456789ABCDEFL); }); // Incorrect return type checkWMTE(() -> { // reference class Void r = (Void) hs.get(am, methodType(Void.class, long[].class, int.class, long.class)). - invokeExact(array, 0, 1L); + invokeExact(array, 0, 0x0123456789ABCDEFL); }); checkWMTE(() -> { // primitive class boolean x = (boolean) hs.get(am, methodType(boolean.class, long[].class, int.class, long.class)). - invokeExact(array, 0, 1L); + invokeExact(array, 0, 0x0123456789ABCDEFL); }); // Incorrect arity checkWMTE(() -> { // 0 @@ -2141,7 +2141,7 @@ }); checkWMTE(() -> { // > long x = (long) hs.get(am, methodType(long.class, long[].class, int.class, long.class, Class.class)). - invokeExact(array, 0, 1L, Void.class); + invokeExact(array, 0, 0x0123456789ABCDEFL, Void.class); }); } }