Changeset 11821


Ignore:
Timestamp:
05/03/09 12:19:19 (14 years ago)
Author:
ehuelsmann
Message:

Be more exact on determining 'being enclosed by a block which
sets (= modifies) the environment'.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/abcl/src/org/armedbear/lisp/jvm.lisp

    r11820 r11821  
    364364  ;; If non-nil, the TAGBODY contains local blocks which "contaminate" the
    365365  ;; environment, with GO forms in them which target tags in this TAGBODY
     366  ;; Non-nil if and only if the block doesn't modify the environment
    366367  needs-environment-restoration
    367368  ;; If non-nil, register containing saved dynamic environment for this block.
     
    401402
    402403
    403 (defknown enclosed-by-protected-block-p (&optional outermost-block) boolean)
     404(defknown enclosed-by-protected-block-p (&optional t) boolean)
    404405(defun enclosed-by-protected-block-p (&optional outermost-block)
    405406  "Indicates whether the code being compiled/analyzed is enclosed in
     
    413414      (return-from enclosed-by-protected-block-p t))))
    414415
    415 (defknown enclosed-by-environment-setting-block-p (&optional outermost-block)
    416   boolean)
     416(defknown enclosed-by-environment-setting-block-p (&optional t) boolean)
    417417(defun enclosed-by-environment-setting-block-p (&optional outermost-block)
    418418  (dolist (enclosing-block *blocks*)
    419419    (when (eq enclosing-block outermost-block)
    420420      (return nil))
    421     (when (block-environment-register enclosing-block)
     421    (when (and (block-environment-register enclosing-block)
     422               (not (block-needs-environment-restoration enclosing-block)))
    422423      (return t))))
    423424
Note: See TracChangeset for help on using the changeset viewer.