(unless (or (constant-p v)
(and (global-var-p v)
(member (global-var-kind v)
- '(:global :special :constant))))
+ '(:global :special))))
(barf "strange *FREE-VARIABLES* entry: ~S" v))
(dolist (n (leaf-refs v))
(check-node-reached n))
;; scrubbing old data II: dangling forward references
;;
- ;; (This could happen if someone does PROCLAIM FTYPE in macroexpansion,
- ;; which is bad style, or at compile time, e.g. in EVAL-WHEN (:COMPILE)
- ;; inside something like DEFSTRUCT, in which case it's reasonable style.
- ;; Either way, it's no longer a free function.)
+ ;; (This could happen if someone executes PROCLAIM FTYPE at
+ ;; macroexpansion time, which is bad style, or at compile time, e.g.
+ ;; in EVAL-WHEN (:COMPILE) inside something like DEFSTRUCT, in which
+ ;; case it's reasonable style. Either way, NAME is no longer a free
+ ;; function.)
(when (boundp '*free-functions*) ; when compiling
(remhash name *free-functions*))
(find-free-variable name))))
(etypecase leaf
(leaf
- (when (or (constant-p leaf)
- (and (global-var-p leaf)
- (eq (global-var-kind leaf) :constant)))
+ (when (constant-p leaf)
(compiler-error "~S is a constant and thus can't be set." name))
(when (and (lambda-var-p leaf)
(lambda-var-ignorep leaf))
(not (eq (defined-fun-inlinep leaf) :notinline)))
(global-var
(case (global-var-kind leaf)
- (:global-function t)
- (:constant t))))))
+ (:global-function t))))))
;;; If we have a non-set LET var with a single use, then (if possible)
;;; replace the variable reference's CONT with the arg continuation.
(compiler-error
"~S is an alien variable and so can't be declared special."
name))
- (when (or (not (global-var-p found))
- (eq (global-var-kind found) :constant))
+ (unless (global-var-p found)
(compiler-error
"~S is a constant and so can't be declared special."
name))
(global-var
(let ((unsafe (policy node (zerop safety))))
(ecase (global-var-kind leaf)
- ((:special :global :constant)
+ ((:special :global)
(aver (symbolp name))
(let ((name-tn (emit-constant name)))
(if unsafe
(def!struct (global-var (:include basic-var))
;; kind of variable described
(kind (missing-arg)
- :type (member :special :global-function :constant :global)))
+ :type (member :special :global-function :global)))
(defprinter (global-var :identity t)
name
(type :test (not (eq type *universal-type*)))
;;; for internal versions, especially for internal versions off the
;;; main CVS branch, it gets hairier, e.g. "0.pre7.14.flaky4.13".)
-"0.pre7.83"
+"0.pre7.84"