Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKen Ryall2008-02-05 17:48:54 -0500
committerKen Ryall2008-02-05 17:48:54 -0500
commit695417b5ccea4c7ad32e517a8dc9a162ece5db0f (patch)
tree28eee58e8b941d712808b78d54c1fb9b97ead320
parent769a6f0c65a8413f5c5cdeebf15c663903cd69fa (diff)
downloadorg.eclipse.cdt-695417b5ccea4c7ad32e517a8dc9a162ece5db0f.tar.gz
org.eclipse.cdt-695417b5ccea4c7ad32e517a8dc9a162ece5db0f.tar.xz
org.eclipse.cdt-695417b5ccea4c7ad32e517a8dc9a162ece5db0f.zip
Bug 217493
-rw-r--r--debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CValue.java4
1 files changed, 2 insertions, 2 deletions
diff --git a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CValue.java b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CValue.java
index 45f4dd374ea..aaf6b59a6a4 100644
--- a/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CValue.java
+++ b/debug/org.eclipse.cdt.debug.core/src/org/eclipse/cdt/debug/internal/core/model/CValue.java
@@ -445,7 +445,7 @@ public class CValue extends AbstractCValue {
}
else if ( CVariableFormat.BINARY.equals( format ) ) {
StringBuffer sb = new StringBuffer( "0b" ); //$NON-NLS-1$
- String stringValue = Long.toBinaryString( new Float( floatValue ).longValue() );
+ String stringValue = Long.toBinaryString( Float.floatToIntBits(floatValue) );
sb.append( (stringValue.length() > 32) ? stringValue.substring( stringValue.length() - 32 ) : stringValue );
return sb.toString();
}
@@ -474,7 +474,7 @@ public class CValue extends AbstractCValue {
}
else if ( CVariableFormat.BINARY.equals( format ) ) {
StringBuffer sb = new StringBuffer( "0b" ); //$NON-NLS-1$
- String stringValue = Long.toHexString( new Double( doubleValue ).longValue() );
+ String stringValue = Long.toBinaryString( Double.doubleToLongBits(doubleValue) );
sb.append( (stringValue.length() > 64) ? stringValue.substring( stringValue.length() - 64 ) : stringValue );
return sb.toString();
}

Back to the top