From 044e9fe9cf51041b57a364a8dbc3b8638e6cb6a8 Mon Sep 17 00:00:00 2001
From: ram <ram>
Date: Sat, 29 Oct 1994 04:38:46 +0000
Subject: [PATCH] Fix of-type to weaken declaration when the init is not of the
 right type.

---
 code/loop.lisp | 10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

diff --git a/code/loop.lisp b/code/loop.lisp
index d2c79d039..01c63395d 100644
--- a/code/loop.lisp
+++ b/code/loop.lisp
@@ -1117,7 +1117,15 @@ collected result will be returned as the value of the LOOP."
 		;; type specifier is unambiguously, and without need of translation,
 		;; a common lisp type specifier or pattern (matching the variable) thereof.
 		(loop-pop-source)
-		(loop-pop-source))
+		#-cmu
+		(loop-pop-source)
+		#+cmu
+		(let* ((spec (loop-pop-source))
+		       (init (loop-typed-init spec)))
+		  (if (typep init spec)
+		      spec
+		      `(or (member ,init) spec))))
+		      
 	       ((symbolp z)
 		;;This is the (sort of) "old" syntax, even though we didn't used to support all of
 		;; these type symbols.
-- 
GitLab