Lines Matching defs:e

125      * the reporting task based on the runtime type of `e` according to
137 public function reportError(Parser $recognizer, RecognitionException $e) : void
148 if ($e instanceof NoViableAltException) {
149 $this->reportNoViableAlternative($recognizer, $e);
150 } elseif ($e instanceof InputMismatchException) {
151 $this->reportInputMismatch($recognizer, $e);
152 } elseif ($e instanceof FailedPredicateException) {
153 $this->reportFailedPredicate($recognizer, $e);
155 $recognizer->notifyErrorListeners($e->getMessage(), $e->getOffendingToken(), $e);
166 public function recover(Parser $recognizer, RecognitionException $e) : void
318 * @param NoViableAltException $e The recognition exception.
322 protected function reportNoViableAlternative(Parser $recognizer, NoViableAltException $e) : void
329 $startToken = $e->getStartToken();
338 $input = $tokens->getTextByTokens($e->getStartToken(), $e->getOffendingToken());
344 $recognizer->notifyErrorListeners($msg, $e->getOffendingToken(), $e);
352 * @param InputMismatchException $e The recognition exception.
356 protected function reportInputMismatch(Parser $recognizer, InputMismatchException $e) : void
358 $expectedTokens = $e->getExpectedTokens();
366 $this->getTokenErrorDisplay($e->getOffendingToken()),
370 $recognizer->notifyErrorListeners($msg, $e->getOffendingToken(), $e);
378 * @param FailedPredicateException $e The recognition exception.
382 protected function reportFailedPredicate(Parser $recognizer, FailedPredicateException $e) : void
384 $msg = \sprintf('rule %s %s', $recognizer->getCurrentRuleName(), $e->getMessage());
386 $recognizer->notifyErrorListeners($msg, $e->getOffendingToken(), $e);
768 * from within the rule; i.e., the FIRST computation done by