Skip to content
Snippets Groups Projects
Commit 114cd482 authored by pfdietz's avatar pfdietz
Browse files

Make it use subtypep instead

parent aa6c0e8f
No related branches found
No related tags found
No related merge requests found
...@@ -156,9 +156,12 @@ ...@@ -156,9 +156,12 @@
(deftest sxhash.17 (deftest sxhash.17
(loop for c1 in '(0.0s0 0.0f0 0.0d0 0.0l0) (loop for c1 in '(0.0s0 0.0f0 0.0d0 0.0l0)
for c2 in '(-0.0s0 -0.0f0 -0.0d0 -0.0l0) for c2 in '(-0.0s0 -0.0f0 -0.0d0 -0.0l0)
for t1 = (type-of c1)
for t2 = (type-of c2)
for sx1 = (sxhash c1) for sx1 = (sxhash c1)
for sx2 = (sxhash c2) for sx2 = (sxhash c2)
unless (or (not (equal (type-of c1) (type-of c2))) unless (or (not (subtypep t1 t2))
(not (subtypep t2 t1))
(eql sx1 sx2)) (eql sx1 sx2))
collect (list c1 c2 sx1 sx2)) collect (list c1 c2 sx1 sx2))
nil) nil)
...@@ -168,9 +171,12 @@ ...@@ -168,9 +171,12 @@
for c1 = (complex r1) for c1 = (complex r1)
for r2 in '(-0.0s0 -0.0f0 -0.0d0 -0.0l0) for r2 in '(-0.0s0 -0.0f0 -0.0d0 -0.0l0)
for c2 = (complex r2) for c2 = (complex r2)
for t1 = (type-of c1)
for t2 = (type-of c2)
for sx1 = (sxhash c1) for sx1 = (sxhash c1)
for sx2 = (sxhash c2) for sx2 = (sxhash c2)
unless (or (not (equal (type-of c1) (type-of c2))) unless (or (not (subtypep t1 t2))
(not (subtypep t2 t1))
(eql sx1 sx2)) (eql sx1 sx2))
collect (list c1 c2 sx1 sx2)) collect (list c1 c2 sx1 sx2))
nil) nil)
...@@ -180,9 +186,12 @@ ...@@ -180,9 +186,12 @@
for c1 = (complex 0 r1) for c1 = (complex 0 r1)
for r2 in '(-0.0s0 -0.0f0 -0.0d0 -0.0l0) for r2 in '(-0.0s0 -0.0f0 -0.0d0 -0.0l0)
for c2 = (complex 0 r2) for c2 = (complex 0 r2)
for t1 = (type-of c1)
for t2 = (type-of c2)
for sx1 = (sxhash c1) for sx1 = (sxhash c1)
for sx2 = (sxhash c2) for sx2 = (sxhash c2)
unless (or (not (equal (type-of c1) (type-of c2))) unless (or (not (subtypep t1 t2))
(not (subtypep t2 t1))
(eql sx1 sx2)) (eql sx1 sx2))
collect (list c1 c2 sx1 sx2)) collect (list c1 c2 sx1 sx2))
nil) nil)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment