Changeset 15302


Ignore:
Timestamp:
Apr 7, 2012, 11:19:14 PM (7 years ago)
Author:
gb
Message:

Don't locally bind the names of globally-defined CL functions; we may
warn about that soon.

Location:
trunk/source
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/level-1/l1-error-system.lisp

    r15237 r15302  
    13521352
    13531353(flet ((io-stream-p (x) (and (streamp x) (eq (stream-direction x) :io)))
    1354        (input-stream-p (x) (and (streamp x) (input-stream-p x)))
    1355        (output-stream-p (x) (and (streamp x) (output-stream-p x)))
     1354       (is-input-stream-p (x) (and (streamp x) (input-stream-p x)))
     1355       (is-output-stream-p (x) (and (streamp x) (output-stream-p x)))
    13561356       (default-terminal-io () (make-echoing-two-way-stream *stdin* *stdout*))
    13571357       (terminal-io () *terminal-io*)
     
    13631363  (check-error-global '*query-io* #'io-stream-p #'terminal-io)
    13641364  (check-error-global '*debug-io* #'io-stream-p #'terminal-io)
    1365   (check-error-global '*standard-input* #'input-stream-p #'terminal-io)
    1366   (check-error-global '*standard-output* #'output-stream-p #'terminal-io)
    1367   (check-error-global '*error-output* #'output-stream-p #'standard-output)
    1368   (check-error-global '*trace-output* #'output-stream-p #'standard-output))
    1369 
     1365  (check-error-global '*standard-input* #'is-input-stream-p #'terminal-io)
     1366  (check-error-global '*standard-output* #'is-output-stream-p #'terminal-io)
     1367  (check-error-global '*error-output* #'is-output-stream-p #'standard-output)
     1368  (check-error-global '*trace-output* #'is-output-stream-p #'standard-output))
     1369
  • trunk/source/lib/macros.lisp

    r15236 r15302  
    444444                (handler-case (return-from ,normal-return ,form)
    445445                  ,@(remove no-error-clause clauses)))))))
    446       (flet ((handler-case (type var &rest body)
     446      (flet ((handler-case-aux (type var &rest body)
    447447               (when (eq type :no-error)
    448448                 (signal-program-error "Duplicate :no-error clause. "))
     
    453453                 (cluster (gensym)))
    454454             (multiple-value-bind (type var body)
    455                                   (apply #'handler-case (car clauses))
     455                                  (apply #'handler-case-aux (car clauses))
    456456               (if var
    457457                 `(block ,block
     
    476476                 (setq index (1+ index))
    477477                 (multiple-value-bind (type var body)
    478                                       (apply #'handler-case (pop clauses))                   
     478                                      (apply #'handler-case-aux (pop clauses))                   
    479479                   (push `',type handlers)
    480480                   (push index handlers)
     
    22252225
    22262226(defmacro define-condition (name (&rest supers) (&rest slots) &body options)
    2227   "DEFINE-CONDITION Name (Parent-Type*) (Slot-Spec*) Option*
    2228    Define NAME as a condition type. This new type inherits slots and its
    2229    report function from the specified PARENT-TYPEs. A slot spec is a list of:
    2230      (slot-name :reader <rname> :initarg <iname> {Option Value}*
    2231 
    2232    The DEFINE-CLASS slot options :ALLOCATION, :INITFORM, [slot] :DOCUMENTATION
    2233    and :TYPE and the overall options :DEFAULT-INITARGS and
    2234    [type] :DOCUMENTATION are also allowed.
    2235 
    2236    The :REPORT option is peculiar to DEFINE-CONDITION. Its argument is either
    2237    a string or a two-argument lambda or function name. If a function, the
    2238    function is called with the condition and stream to report the condition.
    2239    If a string, the string is printed.
    2240 
    2241    Condition types are classes, but (as allowed by ANSI and not as described in
    2242    CLtL2) are neither STANDARD-OBJECTs nor STRUCTURE-OBJECTs. WITH-SLOTS and
    2243    SLOT-VALUE may not be used on condition objects."
    2244   ; If we could tell what environment we're being expanded in, we'd
    2245   ; probably want to check to ensure that all supers name conditions
    2246   ; in that environment.
     2227  ;; If we could tell what environment we're being expanded in, we'd
     2228  ;; probably want to check to ensure that all supers name conditions
     2229  ;; in that environment.
    22472230  (let ((classopts nil)
    22482231        (duplicate nil)
Note: See TracChangeset for help on using the changeset viewer.