コード例 #1
0
 public Stream<Node> nodeStream(boolean includeInlinedNodes) {
   Iterator<Node> iterator;
   TruffleInlining inliner = getInlining();
   if (includeInlinedNodes && inliner != null) {
     iterator = inliner.makeNodeIterator(this);
   } else {
     iterator = NodeUtil.makeRecursiveIterator(this.getRootNode());
   }
   return StreamSupport.stream(Spliterators.spliteratorUnknownSize(iterator, 0), false);
 }
コード例 #2
0
 public void accept(NodeVisitor visitor, boolean includeInlinedNodes) {
   TruffleInlining inliner = getInlining();
   if (includeInlinedNodes && inliner != null) {
     inlining.accept(this, visitor);
   } else {
     getRootNode().accept(visitor);
   }
 }