Lines Matching refs:config
129 * Adding a new config means merging contexts with existing configs for
139 public function add(ATNConfig $config, ?DoubleKeyMap $mergeCache = null) : bool
145 if ($config->semanticContext !== SemanticContext::none()) {
149 if ($config->reachesIntoOuterContext > 0) {
158 $existing = $this->configLookup->getOrAdd($config);
160 if ($existing->equals($config)) {
163 $this->configs[] = $config; // track order here
171 if ($existing->context === null || $config->context === null) {
175 $merged = PredictionContext::merge($existing->context, $config->context, $rootIsWildcard, $mergeCache);
177 // No need to check for existing->context, config->context in cache
182 $config->reachesIntoOuterContext
186 if ($config->isPrecedenceFilterSuppressed()) {
209 foreach ($this->configs as $config) {
210 if ($config !== null) {
211 $states->add($config->state);
226 foreach ($this->configs as $config) {
227 if ($config !== null) {
228 $alts->add($config->alt);
241 foreach ($this->configs as $config) {
242 if ($config->semanticContext !== SemanticContext::none()) {
243 $predicates[] = $config->semanticContext;
265 foreach ($this->configs as $config) {
266 if ($config !== null && $config->context !== null) {
267 $config->context = $interpreter->getCachedContext($config->context);
277 foreach ($configs as $config) {
278 $this->add($config);