From d361efd1bb0dd4e1ceb19b601d309b9fe556f021 Mon Sep 17 00:00:00 2001 From: rtoy <rtoy> Date: Wed, 13 Jul 2005 18:24:56 +0000 Subject: [PATCH] The deftransform for - should be constrained to operate only on constant-argument's of type number instead of t. This fixes ansi-test misc.149a, misc.149, and misc.108. We should probably examine other deftransforms to make sure they only get called on other constant-argument's of the appropriate type. --- compiler/srctran.lisp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/compiler/srctran.lisp b/compiler/srctran.lisp index cd6f22936..348681b75 100644 --- a/compiler/srctran.lisp +++ b/compiler/srctran.lisp @@ -5,7 +5,7 @@ ;;; Carnegie Mellon University, and has been placed in the public domain. ;;; (ext:file-comment - "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/srctran.lisp,v 1.158 2005/07/13 17:16:40 rtoy Exp $") + "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/compiler/srctran.lisp,v 1.159 2005/07/13 18:24:56 rtoy Exp $") ;;; ;;; ********************************************************************** ;;; @@ -3240,7 +3240,7 @@ ;;; If y is not constant, not zerop, or is contagious, or a negative ;;; float -0.0 then give up because (- -0.0 -0.0) is 0.0, not -0.0. ;;; -(deftransform - ((x y) (t (constant-argument t)) * :when :both) +(deftransform - ((x y) (t (constant-argument number)) * :when :both) "fold zero arg" (let ((val (continuation-value y))) (unless (and (zerop val) -- GitLab