php_parser.php
protected function dispatchTokens($unmatched, $matched, $mode = false)
    {
        if (! $this->invokeParser($unmatched, LEXER_UNMATCHED)) {
            return false;
        }
        if (is_bool($mode)) {
            return $this->invokeParser($matched, LEXER_MATCHED);
        }
        if ($this->isModeEnd($mode)) {
            if (! $this->invokeParser($matched, LEXER_EXIT)) {
                return false;
            }

            return $this->mode->leave();
        }
        if ($this->isSpecialMode($mode)) {
            $this->mode->enter($this->decodeSpecial($mode));
            if (! $this->invokeParser($matched, LEXER_SPECIAL)) {
                return false;
            }

            return $this->mode->leave();
        }
        $this->mode->enter($mode);

        return $this->invokeParser($matched, LEXER_ENTER);
    }
protected function dispatchTokens($unmatched, $matched, $mode = false)
    {
        if (! $this->invokeParser($unmatched, LEXER_UNMATCHED)) {
            return false;
        }
        if (is_bool($mode)) {
            return $this->invokeParser($matched, LEXER_MATCHED);
        }
        if ($this->isModeEnd($mode)) {
            if (! $this->invokeParser($matched, LEXER_EXIT)) {
                return false;
            }

            return $this->mode->leave();
        }
        if ($this->isSpecialMode($mode)) {
            $this->mode->enter($this->decodeSpecial($mode));
            if (! $this->invokeParser($matched, LEXER_SPECIAL)) {
                return false;
            }

            return $this->mode->leave();
        }
        $this->mode->enter($mode);

        return $this->invokeParser($matched, LEXER_ENTER);
    }
Sends the matched token and any leading unmatched text
to the parser changing the lexer to a new mode if one is listed.

@param string $unmatched    Unmatched leading portion.
@param string $matched      Actual token match.
@param string $mode         Mode after match. A boolean false mode causes no change.

@return bool             False if there was any error from the parser.