Commit 49ac8b1a authored by pfdietz's avatar pfdietz

Move approx= to ansi-aux.lsp

parent 58141c01
...@@ -1034,4 +1034,8 @@ the condition to go uncaught if it cannot be classified." ...@@ -1034,4 +1034,8 @@ the condition to go uncaught if it cannot be classified."
(let ((eps 1.0d-4)) (let ((eps 1.0d-4))
(<= (abs (- x y)) (<= (abs (- x y))
(* eps (max (abs x) (abs y)))))) (* eps (max (abs x) (abs y))))))
|# |#
\ No newline at end of file
;;; Approximate equality function
(defun approx= (x y &optional (eps (epsilon x)))
(<= (abs (/ (- x y) (max (abs x) 1))) eps))
...@@ -334,10 +334,6 @@ ...@@ -334,10 +334,6 @@
do (setq eps next-eps) do (setq eps next-eps)
finally (return (values i eps (float eps one)))))) finally (return (values i eps (float eps one))))))
;;; Approximate equality function
(defun approx= (x y &optional (eps (epsilon x)))
(<= (abs (/ (- x y) (max (abs x) 1))) eps))
(defun test-log-op-with-decls (op xlo xhi ylo yhi niters (defun test-log-op-with-decls (op xlo xhi ylo yhi niters
&optional &optional
(decls '((optimize (speed 3) (safety 1) (decls '((optimize (speed 3) (safety 1)
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment