Changeset 13115 for trunk/abcl/src/org


Ignore:
Timestamp:
01/01/11 12:07:44 (11 years ago)
Author:
ehuelsmann
Message:

Add SOME-NESTED-BLOCK function to work with hierarchical block structures.

File:
1 edited

Legend:

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

    r13114 r13115  
    575575      (return block))))
    576576
     577(defun some-nested-block (block predicate)
     578  "Applies `predicate` recursively to the children of `block`,
     579until predicate returns non-NIL, returning that value."
     580  (some #'(lambda (b)
     581      (or (funcall predicate b)
     582    (some-nested-block b predicate)))
     583  (node-children block)))
     584
    577585(defknown node-constant-p (t) boolean)
    578586(defun node-constant-p (object)
Note: See TracChangeset for help on using the changeset viewer.