This is guile-procedures.txt, produced by makeinfo version 6.7 from
guile-procedures.texi.

grecs-node?
 -- Scheme Procedure: grecs-node? obj
     Returns '#t' if OBJ is a valid tree node.

   grecs-node-root
 -- Scheme Procedure: grecs-node-root node
     Returns the topmost node that can be traced up from NODE.

   grecs-node-head
 -- Scheme Procedure: grecs-node-head node
     Returns the first node having the same parent and located on the
     same nesting level as NODE.  I.e.  the following always holds true:

          (let ((head (grecs-node-head node)))
            (and
              (eq? (grecs-node-up node) (grecs-node-up head))
              (not (grecs-node-prev? head))))

   grecs-node-tail
 -- Scheme Procedure: grecs-node-tail node
     Returns the last node having the same parent and located on the
     same nesting level as node.  In other words, the following relation
     is always '#t':

          (let ((tail (grecs-node-tail node)))
            (and
              (eq? (grecs-node-up node) (grecs-node-up tail))
                   (not (grecs-node-next? tail))))

   grecs-node-up?
 -- Scheme Procedure: grecs-node-up? node
     Return true if NODE has a parent node.

   grecs-node-up
 -- Scheme Procedure: grecs-node-up node
     Return parent node of NODE.

   grecs-node-down?
 -- Scheme Procedure: grecs-node-down? node
     Returns '#t' if NODE has child nodes.

   grecs-node-down
 -- Scheme Procedure: grecs-node-down node
     Returns the first child node of NODE.

   grecs-node-next?
 -- Scheme Procedure: grecs-node-next? node
     Returns '#t' if NODE is followed by another node on the same
     nesting level.

   grecs-node-next
 -- Scheme Procedure: grecs-node-next node
     Returns the node following NODE on the same nesting level.

   grecs-node-prev?
 -- Scheme Procedure: grecs-node-prev? node
     Returns '#t' if NODE is preceded by another node on the same
     nesting level.

   grecs-node-prev
 -- Scheme Procedure: grecs-node-prev node
     Returns the node preceding NODE on the same nesting level.

   grecs-node-ident
 -- Scheme Procedure: grecs-node-ident node
     Returns identifier of the node NODE.

   grecs-node-ident-locus
 -- Scheme Procedure: grecs-node-ident-locus node [full]
     Returns locus of the NODE's identifier.  Returned value is a cons
     whose parts depend on FULL, which is a boolean value.  If FULL is
     '#f', which is the default, then returned value is a cons:

          (FILE-NAME . LINE-NUMBER)

     Oherwise, if FULL is '#t', the function returns the locations where
     the node begins and ends:
          ((BEG-FILE-NAME BEG-LINE BEG-COLUMN) .
           (END-FILE-NAME END-LINE END-COLUMN))

   grecs-node-path-list
 -- Scheme Procedure: grecs-node-path-list node
     Returns the full path to the node, converted to a list.  Each list
     element corresponds to a subnode identifier.  A subnode which has a
     tag is represented by a cons, whose car contains the subnode
     identifier, and cdr its value.  For example, the following path:

          .foo.bar=x.baz

     is represented as

          '("foo" ("bar" . "x") "baz")

   grecs-node-path
 -- Scheme Procedure: grecs-node-path node [delim]
     Returns the full path to the NODE (a string).

   grecs-node-type
 -- Scheme Procedure: grecs-node-type node
     Returns the type of the node.  The following constants are defined:

     grecs-node-root
          The node is a root node.  The following is always '#t':

               (and (= (grecs-node-type node) grecs-node-root)
                    (not (grecs-node-up? node))
                    (not (grecs-node-prev? node)))
     grecs-node-stmt
          The node is a simple statement.  The following is always '#t':

               (and (= (grecs-node-type node) grecs-node-stmt)
                    (not (grecs-node-down? node)))
     grecs-node-block
          The node is a block statement.

   grecs-node-has-value?
 -- Scheme Procedure: grecs-node-has-value? node
     Returns '#t' if NODE has a value.

   grecs-node-value
 -- Scheme Procedure: grecs-node-value node
     Returns the value of NODE.

   grecs-node-value-locus
 -- Scheme Procedure: grecs-node-value-locus node [full]
     Returns locus of the NODE's value.  Returned value is a cons whose
     parts depend on FULL, which is a boolean value.  If FULL is '#f',
     which is the default, then returned value is a cons:

          (FILE-NAME . LINE-NUMBER)

     Oherwise, if FULL is '#t', the function returns the locations where
     the node begins and ends:
          ((BEG-FILE-NAME BEG-LINE BEG-COLUMN) .
           (END-FILE-NAME END-LINE END-COLUMN))

   grecs-node-locus
 -- Scheme Procedure: grecs-node-locus node [full]
     Returns source location of the NODE.  Returned value is a cons
     whose parts depend on FULL, which is a boolean value.  If FULL is
     '#f', which is the default, then returned value is a cons:

          (FILE-NAME . LINE-NUMBER)

     Oherwise, if FULL is '#t', the function returns the locations where
     the node begins and ends:
          ((BEG-FILE-NAME BEG-LINE BEG-COLUMN) .
           (END-FILE-NAME END-LINE END-COLUMN))

   grecs-find-node
 -- Scheme Procedure: grecs-find-node node path
     Returns the first node whose path is PATH.  Starts search from
     NODE.

   grecs-match-first
 -- Scheme Procedure: grecs-match-first node pattern
     Returns the first node whose path matches PATTERN.  The search is
     started from NODE.

   grecs-match-next
 -- Scheme Procedure: grecs-match-next node
     NODE must be a node returned by a previous call to
     'grecs-match-first' or 'grecs-match-next'.  The function returns
     next node matching the initial pattern, or '#f' if no more matches
     are found.  For example, the following code iterates over all nodes
     matching PATTERN:

          (define (iterate-nodes root pattern thunk)
            (do ((node (grecs-match-first root pattern)
                       (grecs-match-next node)))
                ((not node))
               (thunk node)))



Tag Table:

End Tag Table


Local Variables:
coding: utf-8
End:
