jdk/src/java.base/share/classes/java/nio/Heap-X-Buffer.java.template
changeset 33662 747a61ad0977
parent 31873 87b015c2cd36
child 33665 0599d4cde183
equal deleted inserted replaced
33497:3fadd7701c2f 33662:747a61ad0977
   475     // float
   475     // float
   476 
   476 
   477 #if[rw]
   477 #if[rw]
   478 
   478 
   479     public float getFloat() {
   479     public float getFloat() {
   480         int x = unsafe.getIntUnaligned(hb, byteOffset(nextPutIndex(4)), bigEndian);
   480         int x = unsafe.getIntUnaligned(hb, byteOffset(nextGetIndex(4)), bigEndian);
   481         return Float.intBitsToFloat(x);
   481         return Float.intBitsToFloat(x);
   482     }
   482     }
   483 
   483 
   484     public float getFloat(int i) {
   484     public float getFloat(int i) {
   485         int x = unsafe.getIntUnaligned(hb, byteOffset(checkIndex(i, 4)), bigEndian);
   485         int x = unsafe.getIntUnaligned(hb, byteOffset(checkIndex(i, 4)), bigEndian);