test/jdk/java/lang/invoke/VarHandles/VarHandleTestByteArrayAsFloat.java
changeset 53284 a995647f4911
parent 52914 4fa75d8ad418
child 53662 26ecda724028
equal deleted inserted replaced
53283:f7491df4fd3a 53284:a995647f4911
     1 /*
     1 /*
     2  * Copyright (c) 2015, 2018, Oracle and/or its affiliates. All rights reserved.
     2  * Copyright (c) 2015, 2019, Oracle and/or its affiliates. All rights reserved.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     4  *
     4  *
     5  * This code is free software; you can redistribute it and/or modify it
     5  * This code is free software; you can redistribute it and/or modify it
     6  * under the terms of the GNU General Public License version 2 only, as
     6  * under the terms of the GNU General Public License version 2 only, as
     7  * published by the Free Software Foundation.
     7  * published by the Free Software Foundation.
    91 
    91 
    92         for (int i = 0; i < vhs1.length; i++) {
    92         for (int i = 0; i < vhs1.length; i++) {
    93             for (int j = 0; j < vhs1.length; j++) {
    93             for (int j = 0; j < vhs1.length; j++) {
    94                 if (i == j) {
    94                 if (i == j) {
    95                     assertEquals(vhs1[i], vhs1[i]);
    95                     assertEquals(vhs1[i], vhs1[i]);
    96                     assertEquals(vhs1[i], vhs2[i]);
       
    97                     assertEquals(vhs1[i].hashCode(), vhs2[i].hashCode());
       
    98                 }
    96                 }
    99                 else {
    97                 else {
   100                     assertNotEquals(vhs1[i], vhs1[j]);
    98                     assertNotEquals(vhs1[i], vhs1[j]);
   101                     assertNotEquals(vhs1[i], vhs2[j]);
    99                     assertNotEquals(vhs1[i], vhs2[j]);
   102                 }
   100                 }