- (let ((type (specifier-type (first args))))
- (dolist (name (rest args))
- (unless (symbolp name)
- (error "can't declare TYPE of a non-symbol: ~S" name))
- (when (eq (info :variable :where-from name) :declared)
- (let ((old-type (info :variable :type name)))
- (when (type/= type old-type)
- (style-warn "The new TYPE proclamation~% ~S~@
+ (let ((type (specifier-type (first args))))
+ (dolist (name (rest args))
+ (unless (symbolp name)
+ (error "can't declare TYPE of a non-symbol: ~S" name))
+ (with-single-package-locked-error
+ (:symbol name "globally declaring the type of ~A"))
+ (when (eq (info :variable :where-from name) :declared)
+ (let ((old-type (info :variable :type name)))
+ (when (type/= type old-type)
+ (style-warn "The new TYPE proclamation~% ~S~@