code: void bofFixup() {
             //
             //   The parse tree looks like this ...
             //         fTree root  --.       <cat>
             //                               /     \
             //                            <cat>   <#end node>
             //                           /     \
             //                     <bofNode>   rest
             //                               of tree
             //
             //    We will be adding things to the followPos set of the <bofNode>
             //
             RBBINode  bofNode = fRB.fTreeRoots[fRootIx].fLeftChild.fLeftChild;
             Assert.assrt(bofNode.fType == RBBINode.leafChar);
             Assert.assrt(bofNode.fVal == 2);
  
             // Get all nodes that can be the start a match of the user-written rules
             //  (excluding the fake bofNode)
             //  We want the nodes that can start a match in the
             //     part labeled "rest of tree"
             //
             Set<RBBINode> matchStartNodes = fRB.fTreeRoots[fRootIx].fLeftChild.fRightChild.fFirstPosSet;
             for (RBBINode startNode : matchStartNodes) {
                 if (startNode.fType != RBBINode.leafChar) {
                     continue;
                 }
  
                 if (startNode.fVal == bofNode.fVal) {
                     //  We found a leaf node corresponding to a {bof} that was
                     //    explicitly written into a rule.
                     //  Add everything from the followPos set of this node to the
                     //    followPos set of the fake bofNode at the start of the tree.
                     //
                     bofNode.fFollowPos.addAll(startNode.fFollowPos);
                 }
             }
         }
docs: -----------------------------------------------------------------------------