(if (integerp src)
`((,(1+ src) . +))
(when-let* ((range (range src))
- (low (comp-cstr-greatest-in-range range))
+ (low (comp-cstr-smallest-in-range range))
(okay (integerp low)))
`((,(1+ low) . +))))))
(comp-cstr-set-cmp-range dst old-dst ext-range))))
(if (integerp src)
`((,src . +))
(when-let* ((range (range src))
- (low (comp-cstr-greatest-in-range range))
+ (low (comp-cstr-smallest-in-range range))
(okay (integerp low)))
`((,low . +))))))
(comp-cstr-set-cmp-range dst old-dst ext-range))))
(if (integerp src)
`((- . ,(1- src)))
(when-let* ((range (range src))
- (low (comp-cstr-smallest-in-range range))
+ (low (comp-cstr-greatest-in-range range))
(okay (integerp low)))
`((- . ,(1- low)))))))
(comp-cstr-set-cmp-range dst old-dst ext-range))))
(if (integerp src)
`((- . ,src))
(when-let* ((range (range src))
- (low (comp-cstr-smallest-in-range range))
+ (low (comp-cstr-greatest-in-range range))
(okay (integerp low)))
`((- . ,low))))))
(comp-cstr-set-cmp-range dst old-dst ext-range))))
(= x 3))
(error "Not foo or 3"))
x)
- (or (member foo) (integer 3 3)))))
+ (or (member foo) (integer 3 3)))
+
+ ;;58
+ ((defun comp-tests-ret-type-spec-f (x y)
+ (if (and (natnump x)
+ (natnump y)
+ (<= x y))
+ x
+ (error "")))
+ (integer 0 *))
+
+ ;; 59
+ ((defun comp-tests-ret-type-spec-f (x y)
+ (if (and (>= x 3)
+ (<= y 10)
+ (<= x y))
+ x
+ (error "")))
+ (or float (integer 3 10)))
+
+ ;; 60
+ ((defun comp-tests-ret-type-spec-f (x y)
+ (if (and (<= x 10)
+ (>= y 3)
+ (>= x y))
+ x
+ (error "")))
+ (or float (integer 3 10)))))
(defun comp-tests-define-type-spec-test (number x)
`(comp-deftest ,(intern (format "ret-type-spec-%d" number)) ()