[armedbear-cvs] r12880 - branches/generic-class-file/abcl/src/org/armedbear/lisp

Erik Huelsmann ehuelsmann at common-lisp.net
Mon Aug 9 08:49:01 UTC 2010


Author: ehuelsmann
Date: Mon Aug  9 04:48:58 2010
New Revision: 12880

Log:
Fix insertion of floats/doubles in the constant pool.

Modified:
   branches/generic-class-file/abcl/src/org/armedbear/lisp/jvm-class-file.lisp

Modified: branches/generic-class-file/abcl/src/org/armedbear/lisp/jvm-class-file.lisp
==============================================================================
--- branches/generic-class-file/abcl/src/org/armedbear/lisp/jvm-class-file.lisp	(original)
+++ branches/generic-class-file/abcl/src/org/armedbear/lisp/jvm-class-file.lisp	Mon Aug  9 04:48:58 2010
@@ -449,7 +449,8 @@
   "Returns the index of the constant-pool item denoting the float."
   (let ((entry (gethash (cons 4 float) (pool-entries pool))))
     (unless entry
-      (setf entry (make-constant-float (incf (pool-index pool)) float)
+      (setf entry (make-constant-float (incf (pool-index pool))
+                                       (sys::%float-bits float))
             (gethash (cons 4 float) (pool-entries pool)) entry)
       (push entry (pool-entries-list pool)))
     (constant-index entry)))
@@ -468,7 +469,8 @@
   "Returns the index of the constant-pool item denoting the double."
   (let ((entry (gethash (cons 6 double) (pool-entries pool))))
     (unless entry
-      (setf entry (make-constant-double (incf (pool-index pool)) double)
+      (setf entry (make-constant-double (incf (pool-index pool))
+                                        (sys::%float-bits double))
             (gethash (cons 6 double) (pool-entries pool)) entry)
       (push entry (pool-entries-list pool))
       (incf (pool-index pool))) ;; double index increase; 'double' takes 2 slots




More information about the armedbear-cvs mailing list