Skip to content

Commit

Permalink
reconcile to sbcl x86 compiler
Browse files Browse the repository at this point in the history
  • Loading branch information
lisp committed Jul 15, 2010
1 parent 8e83bca commit 7ee3046
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions float.lisp
Expand Up @@ -103,7 +103,8 @@
(#xff
(if (zerop fraction)
(if negative-p single-float-negative-infinity single-float-positive-infinity)
single-float-nan))
#-sbcl single-float-nan
#+sbcl (eval 'single-float-nan)))
(#x00
;; (print (cl:list :to-float sign raw-exponent exponent fraction))
(if (zerop fraction)
Expand Down Expand Up @@ -140,7 +141,8 @@
(#x7ff
(if (zerop fraction)
(if negative-p double-float-negative-infinity double-float-positive-infinity)
double-float-nan))
#-sbcl double-float-nan
#+sbcl (eval 'double-float-nan)))
(#x000
;; (print (cl:list :to-float sign raw-exponent exponent fraction))
(if (zerop fraction)
Expand All @@ -167,7 +169,9 @@
#xff800000)
((= float single-float-positive-infinity)
#x7f800000)
((eql float single-float-nan)
;; allow for sbcl inability to compile code with nan constants
(#-sbcl (eql float single-float-nan)
#+sbcl (sb-ext:float-nan-p float)
;; http://en.wikipedia.org/wiki/NaN#Encodings
;; http://java.sun.com/javase/6/docs/api/java/lang/Double.html#doubleToLongBits(double)
#x7fc00000)
Expand Down Expand Up @@ -208,7 +212,9 @@
#xfff0000000000000)
((= float double-float-positive-infinity)
#x7ff0000000000000)
((eql float double-float-nan)
;; allow for sbcl inability to compile code with nan constants
(#-sbcl (eql float double-float-nan)
#+sbcl (sb-ext:float-nan-p float)
;; http://en.wikipedia.org/wiki/NaN#Encodings
;; http://java.sun.com/javase/6/docs/api/java/lang/Double.html#doubleToLongBits(double)
#x7ff8000000000000)
Expand Down

0 comments on commit 7ee3046

Please sign in to comment.