/[gcl]/gcl/ansi-tests/numbers-aux.lsp
ViewVC logotype

Diff of /gcl/ansi-tests/numbers-aux.lsp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.11 by pfdietz, Fri Sep 5 11:55:24 2003 UTC revision 1.12 by pfdietz, Sat Sep 6 23:31:41 2003 UTC
# Line 44  Line 44 
44            (long-float            (long-float
45             (<= #.(rational most-negative-long-float)             (<= #.(rational most-negative-long-float)
46                 x                 x
47                 #.(rational most-positive-long-float))))))))                     #.(rational most-positive-long-float))))))))
48    
49    ;;; NOTE!  According to section 12.1.4.1, when a rational is compared
50    ;;; to a float, the effect is as if the float is convert to a rational
51    ;;; (by RATIONAL), not as if the rational is converted to a float.
52    ;;; This means the calls to numbers-are-compatible are not necessary.
53    
54  (defun =.4-fn ()  (defun =.4-fn ()
55    (loop for x in *numbers*    (loop for x in *numbers*
56          append          append
57          (loop for y in *numbers*          (loop for y in *numbers*
58                unless (or (not (numbers-are-compatible x y))                unless (or ;; (not (numbers-are-compatible x y))
59                           (if (= x y) (= y x) (not (= y x))))                           (if (= x y) (= y x) (not (= y x))))
60                collect (list x y))))                collect (list x y))))
61    
# Line 58  Line 63 
63    (loop for x in *numbers*    (loop for x in *numbers*
64          append          append
65          (loop for y in *numbers*          (loop for y in *numbers*
66                unless (or (not (numbers-are-compatible x y))                unless (or ;; (not (numbers-are-compatible x y))
67                           (if (/= x y) (/= y x) (not (/= y x))))                           (if (/= x y) (/= y x) (not (/= y x))))
68                collect (list x y))))                collect (list x y))))
69    
# Line 66  Line 71 
71    (loop for x in *numbers*    (loop for x in *numbers*
72          append          append
73          (loop for y in *numbers*          (loop for y in *numbers*
74                when (and (numbers-are-compatible x y)                when (and ;; (numbers-are-compatible x y)
75                          (if (= x y)                          (if (= x y)
76                              (/= x y)                              (/= x y)
77                            (not (/= x y))))                            (not (/= x y))))
# Line 76  Line 81 
81    (loop for x in *reals*    (loop for x in *reals*
82          nconc          nconc
83          (loop for y in *reals*          (loop for y in *reals*
84                when (and (numbers-are-compatible x y)                when (and ;; (numbers-are-compatible x y)
85                          (and (< x y) (> x y)))                          (and (< x y) (> x y)))
86                collect (list x y))))                collect (list x y))))
87    
# Line 84  Line 89 
89    (loop for x in *reals*    (loop for x in *reals*
90          nconc          nconc
91          (loop for y in *reals*          (loop for y in *reals*
92                when (and (numbers-are-compatible x y)                when (and ;; (numbers-are-compatible x y)
93                          (if (< x y) (not (> y x))                          (if (< x y) (not (> y x))
94                            (> y x)))                            (> y x)))
95                collect (list x y))))                collect (list x y))))
# Line 93  Line 98 
98    (loop for x in *reals*    (loop for x in *reals*
99          nconc          nconc
100          (loop for y in *reals*          (loop for y in *reals*
101                when (and (numbers-are-compatible x y)                when (and ;; (numbers-are-compatible x y)
102                          (if (< x y) (>= x y)                          (if (< x y) (>= x y)
103                            (not (>= x y))))                            (not (>= x y))))
104                collect (list x y))))                collect (list x y))))
# Line 102  Line 107 
107    (loop for x in *reals*    (loop for x in *reals*
108          nconc          nconc
109          (loop for y in *reals*          (loop for y in *reals*
110                when (and (numbers-are-compatible x y)                when (and ;; (numbers-are-compatible x y)
111                          (if (<= x y) (not (>= y x))                          (if (<= x y) (not (>= y x))
112                            (>= y x)))                            (>= y x)))
113                collect (list x y))))                collect (list x y))))
# Line 111  Line 116 
116    (loop for x in *reals*    (loop for x in *reals*
117          nconc          nconc
118          (loop for y in *reals*          (loop for y in *reals*
119                when (and (numbers-are-compatible x y)                when (and ;; (numbers-are-compatible x y)
120                          (if (<= x y) (not (or (= x y) (< x y)))                          (if (<= x y) (not (or (= x y) (< x y)))
121                            (or (= x y) (< x y))))                            (or (= x y) (< x y))))
122                collect (list x y))))                collect (list x y))))
# Line 120  Line 125 
125    (loop for x in *reals*    (loop for x in *reals*
126          nconc          nconc
127          (loop for y in *reals*          (loop for y in *reals*
128                when (and (numbers-are-compatible x y)                when (and ;; (numbers-are-compatible x y)
129                          (if (> x y) (<= x y)                          (if (> x y) (<= x y)
130                            (not (<= x y))))                            (not (<= x y))))
131                collect (list x y))))                collect (list x y))))
# Line 129  Line 134 
134    (loop for x in *reals*    (loop for x in *reals*
135          nconc          nconc
136          (loop for y in *reals*          (loop for y in *reals*
137                when (and (numbers-are-compatible x y)                when (and ;; (numbers-are-compatible x y)
138                          (if (>= x y) (not (or (= x y) (> x y)))                          (if (>= x y) (not (or (= x y) (> x y)))
139                            (or (= x y) (> x y))))                            (or (= x y) (> x y))))
140                collect (list x y))))                collect (list x y))))

Legend:
Removed from v.1.11  
changed lines
  Added in v.1.12

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26