From: Paul Khuong Date: Sun, 19 May 2013 14:14:35 +0000 (-0400) Subject: More robust FILTER-LVAR through CASTs X-Git-Url: http://repo.macrolet.net/gitweb/?a=commitdiff_plain;h=587c903b0601dfd6763b5acc05778f793172c915;p=sbcl.git More robust FILTER-LVAR through CASTs * IR1-conversion can insert casts between a combination and its arguments. Handle that case via principal-lvar{-use}. * Fixes a regression in b111015 (lp#1181684). --- diff --git a/src/compiler/ir1util.lisp b/src/compiler/ir1util.lisp index 82bea22..478be97 100644 --- a/src/compiler/ir1util.lisp +++ b/src/compiler/ir1util.lisp @@ -362,7 +362,7 @@ ;; this node. (let* ((node (lvar-use filtered-lvar)) (args (basic-combination-args node)) - (victim (first args))) + (victim (principal-lvar (first args)))) (aver (eq (constant-value (ref-leaf (lvar-use victim))) 'dummy)) diff --git a/tests/compiler.pure.lisp b/tests/compiler.pure.lisp index d1c8656..6e1d150 100644 --- a/tests/compiler.pure.lisp +++ b/tests/compiler.pure.lisp @@ -4459,3 +4459,9 @@ #\1 :y 2)) (let ((p2 #'(lambda (char) (upper-case-p char)))) (funcall p2 s))))) + +(with-test (:name :bug-1181684) + (compile nil `(lambda () + (let ((hash #xD13CCD13)) + (setf hash (logand most-positive-word + (ash hash 5)))))))