gencgc: More precise conservatism for pointers to boxed pages.
[sbcl.git] / src / code / typedefs.lisp
index d9403c2..e652fc4 100644 (file)
         (parse-body body :doc-string-allowed nil)
       `(progn
          (!cold-init-forms
-          (setf (info :type :translator ',name)
-                (lambda (,whole)
-                  (block ,name
-                    (destructuring-bind ,wholeless-arglist
-                        (rest ,whole) ; discarding NAME
-                      ,@decls
-                      ,@forms)))))
+          (let ((fun (lambda (,whole)
+                       (block ,name
+                         (destructuring-bind ,wholeless-arglist
+                             (rest ,whole)  ; discarding NAME
+                           ,@decls
+                       ,@forms)))))
+            #-sb-xc-host
+            (setf (%simple-fun-arglist (the simple-fun fun)) ',wholeless-arglist)
+            (setf (info :type :translator ',name) fun)))
          ',name))))
 
 ;;; DEFVARs for these come later, after we have enough stuff defined.
 #!-sb-fluid (declaim (inline type-list-cache-hash))
 (declaim (ftype (function (list) (unsigned-byte 8)) type-list-cache-hash))
 (defun type-list-cache-hash (types)
-  (logand (loop with res = 0
-             for type in types
-             for hash = (type-hash-value type)
-             do (setq res (logxor res hash))
-             finally (return res))
-          #xFF))
+  (logand #xFF
+          (loop with res fixnum = 0
+                for type in types
+                for hash = (type-hash-value type)
+                do (setq res (logxor res hash))
+                finally (return res))))
 \f
 ;;;; cold loading initializations