Lines Matching refs:closure

54  * caching problem. The closure routine only considers the rule invocation stack
80 * context, because closure can fall off the end of a rule. I tried to cache
127 * In both cases I believe that no closure operations will dip into the outer
136 * it performs closure operations like ANTLR v3 did. It delays predicate
139 * closure, the DFA state configuration sets would be different and we couldn't
154 * During full LL ATN simulation, closure always evaluates predicates and
156 * closure. It hits a landmine when parsing with the Java grammar, for example,
890 protected function computeReachSet(ATNConfigSet $closure, int $t, bool $fullCtx) : ?ATNConfigSet
893 $this->log[] = \sprintf('In computeReachSet, starting closure: %s', (string) $closure);
906 * closure operation, so they are handled separately for the performance
907 * advantage of having a smaller intermediate set when calling closure.
916 foreach ($closure->elements() as $c) {
970 // Don't pursue the closure if there is just one state.
972 // Also don't pursue the closure if there is unique alternative
977 // Also don't pursue the closure if there is unique alternative among the configurations.
982 // If the reach set could not be trivially determined, perform a closure
990 $this->closure($item, $reach, $closureBusy, false, $fullCtx, $treatEofAsEpsilon);
1002 * When reach==intermediate, no closure operation was performed. In
1020 * closure operation reached such a state. This ensures adaptivePredict
1103 $this->closure($c, $configs, $closureBusy, true, $fullCtx, false);
1191 * flag is carried along in closure(). so to avoid adding field, set bit
1211 * - The closure block cannot contain any epsilon transitions which bypass
1212 * the body of the closure, so all states reachable via alternative 1 are
1231 * of both the primary and closure blocks of the left-recursive rule
1585 * closure operations if we reach a DFA state that uniquely predicts
1587 * waste to pursue the closure. Might have to advance when we do
1590 protected function closure(
1625 $this->log[] = \sprintf('closure(%s)', $config->toString(true));
1806 * during closure operations. See antlr/antlr4#1398.
1811 * (traversing only epsilon edges, so we're still in closure, in
1820 * closure is at a StarLoopEntryState generated during LR removal.
1831 * If any is true for each stack top, then closure does not add a
1842 * Do we need to evaluate predicates ever in closure for this case?
1849 * the "primary" part (ID here). If closure is in
1856 * closure starting at edges[0], edges[1] emanating from
1857 * StarLoopEntryState. That means it is not performing closure on
1870 * The lookahead language has not changed because closure chooses
1875 * closure had chosen to enter the choice block immediately.
2092 * during closure, which dramatically reduces the size of
2152 // during closure, which dramatically reduces the size of