Source for file longestfirst.php
Documentation is available at longestfirst.php
class CodeGen_PECL_Tools_ProtoParser
class CodeGen_PECL_Tools_ProtoLexer
function __construct ($data)
private $_yy_stack = array ();
return $this->{'yylex' . $this->_yy_state}();
function yypushstate ($state)
$this->_yy_state = $state;
$this->_yy_state = array_pop($this->_yy_stack);
$this->_yy_state = $state;
'/^[0-9]+|0x[0-9a-fA-F]+/',
'/^[_a-zA-Z][_a-zA-Z0-9]+/',
foreach ($rules as $index => $rule) {
$match = array ($yymatches, $index); // matches, token
$match = array ($yymatches, $index);
throw new Exception ('Unexpected input at line' . $this->line .
': ' . $this->data[$this->count]);
$this->token = $match[1 ];
$this->value = $match[0 ][0 ];
$yysubmatches = $match[0 ];
$r = $this->{'yy_r1_' . $this->token}($yysubmatches);
$this->count += strlen($this->value);
// process this token in the new state
} elseif ($r === false ) {
$this->count += strlen($this->value);
if ($this->count >= strlen($this->data)) {
return false; // end of input
$yy_yymore_patterns = array_slice($rules, $this->token, true );
if (!isset ($yy_yymore_patterns[$this->token])) {
throw new Exception ('cannot do yymore for the last token');
foreach ($yy_yymore_patterns[$this->token] as $index => $rule) {
substr($this->data, $this->count), $yymatches)) {
$yymatches = array_filter($yymatches, 'strlen'); // remove empty sub-patterns
$match = array ($yymatches, $index); // matches, token
$match = array ($yymatches, $index);
throw new Exception ('Unexpected input at line' . $this->line .
': ' . $this->data[$this->count]);
$this->token = $match[1 ];
$this->value = $match[0 ][0 ];
$yysubmatches = $match[0 ];
$r = $this->{'yy_r1_' . $this->token}();
} while ($r !== null || !$r);
// process this token in the new state
$this->count += strlen($this->value);
function yy_r1_0 ($yy_subpatterns)
function yy_r1_1 ($yy_subpatterns)
$this->token = CodeGen_PECL_Tools_ProtoParser ::PAR_OPEN;
function yy_r1_2 ($yy_subpatterns)
$this->token = CodeGen_PECL_Tools_ProtoParser ::PAR_CLOSE;
function yy_r1_3 ($yy_subpatterns)
$this->token = CodeGen_PECL_Tools_ProtoParser ::EQ;
function yy_r1_4 ($yy_subpatterns)
$this->token = CodeGen_PECL_Tools_ProtoParser ::COMMA;
function yy_r1_5 ($yy_subpatterns)
$this->token = CodeGen_PECL_Tools_ProtoParser ::SEMICOLON;
function yy_r1_6 ($yy_subpatterns)
$this->token = CodeGen_PECL_Tools_ProtoParser ::VOID;
function yy_r1_7 ($yy_subpatterns)
$this->token = CodeGen_PECL_Tools_ProtoParser ::BOOL;
function yy_r1_8 ($yy_subpatterns)
$this->token = CodeGen_PECL_Tools_ProtoParser ::NUMVAL;
function yy_r1_9 ($yy_subpatterns)
$this->token = CodeGen_PECL_Tools_ProtoParser ::STRVAL;
$a = new CodeGen_PECL_Tools_ProtoLexer ('booler boolboolean boolean bool');
Documentation generated on Mon, 11 Mar 2019 15:40:41 -0400 by phpDocumentor 1.4.4. PEAR Logo Copyright © PHP Group 2004.
|