PhpPeg\TokenLiteral::match_code PHP Метод

match_code() публичный Метод

The $value default parameter is NOT used, it is just added to conform to interface
public match_code ( $value = NULL )
    function match_code($value = NULL)
    {
        // We inline single-character matches for speed
        if (!$this->contains_expression() && strlen(eval('return ' . $this->value . ';')) == 1) {
            return $this->match_fail_conditional('substr($this->string,$this->pos,1) == ' . $this->value, PHPBuilder::build()->l('$this->pos += 1;', $this->set_text($this->value)));
        }
        return parent::match_code($this->value);
    }