├── README.md ├── composer.json ├── composer.lock ├── grammar ├── analyze.php ├── kmyacc.php.parser ├── rebuildParser.php └── zend_language_parser.phpy └── lib ├── PhpGenerics ├── Autoloader.php ├── Compiler.php ├── Engine.php ├── Generator.php └── Parser.php └── bootstrap.php /README.md: -------------------------------------------------------------------------------- 1 | Muahahahahahahaha 2 | ================= 3 | 4 | I'll let the example speak for itself: 5 | 6 | Example: 7 | 8 | Test/Item.php 9 | 10 | ```php 11 | namespace test; 12 | 13 | class Item { 14 | 15 | protected $item; 16 | 17 | public function __construct(T $item = null) 18 | { 19 | $this->item = $item; 20 | } 21 | 22 | public function getItem() 23 | { 24 | return $item; 25 | } 26 | 27 | public function setItem(T $item) 28 | { 29 | $this->item = $item; 30 | } 31 | } 32 | ``` 33 | 34 | Test/Test.php 35 | 36 | ```php 37 | namespace Test; 38 | 39 | class Test { 40 | public function runTest() 41 | { 42 | $item = new Item; 43 | var_dump($item instanceof Item); // true 44 | $item->setItem(new StdClass); // works fine 45 | // $item->setItem([]); // E_RECOVERABLE_ERROR 46 | } 47 | } 48 | ``` 49 | test.php 50 | 51 | ```php 52 | require "vendor/autoload.php"; 53 | 54 | $test = new Test\Test; 55 | $test->runTest(); 56 | ``` 57 | 58 | ## HOW??? 59 | 60 | Black magic and voodoo. 61 | 62 | ## Where can I use generics? 63 | 64 | Right now, only class definitions can define generics, and any parameter or return type declaration can use them. 65 | 66 | It also supports parameter-expansion: 67 | 68 | ```php 69 | class Foo { 70 | public function bar(): Foo {} 71 | } 72 | ``` 73 | 74 | As far as the rest, I don't know. 75 | 76 | ## Seriously, How??? 77 | 78 | Like I said, black magic. If you want to know, you're going to regret it. 79 | 80 | ## How do I install? 81 | 82 | Since this is black voodoo evilness, I'm not adding it to packagist. Simply add a composer repository pointing here, and composer install. Then just use generics in your code and be happy. 83 | 84 | ## HOW ARE YOU DOING THIS? 85 | 86 | You **really** don't want to know... 87 | 88 | ## Gotchas 89 | 90 | Right now, generic types are not resolved according to use rules. So 91 | 92 | ```php 93 | new Item 94 | ``` 95 | 96 | Always points to `\StdClass`. It will not respect `use` or the present namespace. This is a TODO. 97 | 98 | ## FOR THE LOVE OF GOD, HOW??? 99 | 100 | Fine. Your loss. 101 | 102 | I hijack the composer autoloader, and substitute my own. I then pre-process all autoloaded files, transpiling them to eliminate generics from declarations. I also compile usages from generic syntax to namespace syntax (compiling the types as we go along). 103 | 104 | So: 105 | ```php 106 | new Item 107 | ``` 108 | Becomes 109 | ```php 110 | new Item\①StdClass① 111 | ``` 112 | Then, the autoloader recognizes attempts to load these classes and will generate the templated code... The above 2 blocks of code will be compiled to: 113 | ```php 114 | class test 115 | { 116 | public function runTests() 117 | { 118 | $item = new \test\Item\①StdClass①(new \StdClass()); 119 | $itemList = new \test\ItemList\①StdClass①(); 120 | $itemList->addItem($item); 121 | } 122 | } 123 | ``` 124 | And: 125 | ```php 126 | namespace test\Item; 127 | 128 | class ①StdClass① extends \test\Item 129 | { 130 | protected $item; 131 | 132 | public function __construct(\StdClass $item) 133 | { 134 | $this->item = $item; 135 | } 136 | 137 | public function getItem() 138 | { 139 | return $item; 140 | } 141 | 142 | public function setItem(\StdClass $item) 143 | { 144 | $this->item = $item; 145 | } 146 | } 147 | ``` 148 | ## TL;DR 149 | 150 | TL;DR: don't use this 151 | -------------------------------------------------------------------------------- /composer.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "ircmaxell/generics", 3 | "description": "A generics preprocessor library", 4 | "license": "MIT", 5 | "authors": [ 6 | { 7 | "name": "Anthony Ferrara", 8 | "email": "ircmaxell@gmail.com" 9 | } 10 | ], 11 | "autoload": { 12 | "psr-4": { 13 | "PhpGenerics\\": "lib/PhpGenerics/" 14 | }, 15 | "files": [ 16 | "lib/bootstrap.php" 17 | ] 18 | }, 19 | "require": { 20 | "php": ">=5.4", 21 | "nikic/php-parser": "1.2.*@dev" 22 | } 23 | } 24 | -------------------------------------------------------------------------------- /composer.lock: -------------------------------------------------------------------------------- 1 | { 2 | "_readme": [ 3 | "This file locks the dependencies of your project to a known state", 4 | "Read more about it at http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file", 5 | "This file is @generated automatically" 6 | ], 7 | "hash": "c922ca720951cd604108f7902864f582", 8 | "packages": [ 9 | { 10 | "name": "nikic/php-parser", 11 | "version": "dev-master", 12 | "source": { 13 | "type": "git", 14 | "url": "https://github.com/nikic/PHP-Parser.git", 15 | "reference": "52dafafd10ceaa10c6760523bfa160f1ee3aabfe" 16 | }, 17 | "dist": { 18 | "type": "zip", 19 | "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/52dafafd10ceaa10c6760523bfa160f1ee3aabfe", 20 | "reference": "52dafafd10ceaa10c6760523bfa160f1ee3aabfe", 21 | "shasum": "" 22 | }, 23 | "require": { 24 | "ext-tokenizer": "*", 25 | "php": ">=5.3" 26 | }, 27 | "type": "library", 28 | "extra": { 29 | "branch-alias": { 30 | "dev-master": "1.2-dev" 31 | } 32 | }, 33 | "autoload": { 34 | "files": [ 35 | "lib/bootstrap.php" 36 | ] 37 | }, 38 | "notification-url": "https://packagist.org/downloads/", 39 | "license": [ 40 | "BSD-3-Clause" 41 | ], 42 | "authors": [ 43 | { 44 | "name": "Nikita Popov" 45 | } 46 | ], 47 | "description": "A PHP parser written in PHP", 48 | "keywords": [ 49 | "parser", 50 | "php" 51 | ], 52 | "time": "2015-03-25 19:57:39" 53 | } 54 | ], 55 | "packages-dev": [], 56 | "aliases": [], 57 | "minimum-stability": "stable", 58 | "stability-flags": { 59 | "nikic/php-parser": 20 60 | }, 61 | "prefer-stable": false, 62 | "prefer-lowest": false, 63 | "platform": [], 64 | "platform-dev": [] 65 | } 66 | -------------------------------------------------------------------------------- /grammar/analyze.php: -------------------------------------------------------------------------------- 1 | \'[^\\\\\']*+(?:\\\\.[^\\\\\']*+)*+\') 7 | (?"[^\\\\"]*+(?:\\\\.[^\\\\"]*+)*+") 8 | (?(?&singleQuotedString)|(?&doubleQuotedString)) 9 | (?/\*[^*]*+(?:\*(?!/)[^*]*+)*+\*/) 10 | (?\{[^\'"/{}]*+(?:(?:(?&string)|(?&comment)|(?&code)|/)[^\'"/{}]*+)*+}) 11 | )'; 12 | 13 | const RULE_BLOCK = '(?[a-z_]++):(?[^\'"/{};]*+(?:(?:(?&string)|(?&comment)|(?&code)|/|})[^\'"/{};]*+)*+);'; 14 | 15 | $usedTerminals = array_flip(array( 16 | 'T_VARIABLE', 'T_STRING', 'T_INLINE_HTML', 'T_ENCAPSED_AND_WHITESPACE', 17 | 'T_LNUMBER', 'T_DNUMBER', 'T_CONSTANT_ENCAPSED_STRING', 'T_STRING_VARNAME', 'T_NUM_STRING' 18 | )); 19 | $unusedNonterminals = array_flip(array( 20 | 'case_separator', 'optional_comma' 21 | )); 22 | 23 | function regex($regex) { 24 | return '~' . LIB . '(?:' . str_replace('~', '\~', $regex) . ')~'; 25 | } 26 | 27 | function magicSplit($regex, $string) { 28 | $pieces = preg_split(regex('(?:(?&string)|(?&comment)|(?&code))(*SKIP)(*FAIL)|' . $regex), $string); 29 | 30 | foreach ($pieces as &$piece) { 31 | $piece = trim($piece); 32 | } 33 | 34 | return array_filter($pieces); 35 | } 36 | 37 | echo '
';
38 | 
39 | ////////////////////
40 | ////////////////////
41 | ////////////////////
42 | 
43 | list($defs, $ruleBlocks) = magicSplit('%%', file_get_contents(GRAMMAR_FILE));
44 | 
45 | if ('' !== trim(preg_replace(regex(RULE_BLOCK), '', $ruleBlocks))) {
46 |     die('Not all rule blocks were properly recognized!');
47 | }
48 | 
49 | preg_match_all(regex(RULE_BLOCK), $ruleBlocks, $ruleBlocksMatches, PREG_SET_ORDER);
50 | foreach ($ruleBlocksMatches as $match) {
51 |     $ruleBlockName = $match['name'];
52 |     $rules = magicSplit('\|', $match['rules']);
53 | 
54 |     foreach ($rules as &$rule) {
55 |         $parts = magicSplit('\s+', $rule);
56 |         $usedParts = array();
57 | 
58 |         foreach ($parts as $part) {
59 |             if ('{' === $part[0]) {
60 |                 preg_match_all('~\$([0-9]+)~', $part, $backReferencesMatches, PREG_SET_ORDER);
61 |                 foreach ($backReferencesMatches as $match) {
62 |                     $usedParts[$match[1]] = true;
63 |                 }
64 |             }
65 |         }
66 | 
67 |         $i = 1;
68 |         foreach ($parts as &$part) {
69 |             if ('/' === $part[0]) {
70 |                 continue;
71 |             }
72 | 
73 |             if (isset($usedParts[$i])) {
74 |                 if ('\'' === $part[0] || '{' === $part[0]
75 |                     || (ctype_upper($part[0]) && !isset($usedTerminals[$part]))
76 |                     || (ctype_lower($part[0]) && isset($unusedNonterminals[$part]))
77 |                 ) {
78 |                     $part = '' . $part . '';
79 |                 } else {
80 |                     $part = '' . $part . '';
81 |                 }
82 |             } elseif ((ctype_upper($part[0]) && isset($usedTerminals[$part]))
83 |                       || (ctype_lower($part[0]) && !isset($unusedNonterminals[$part]))
84 | 
85 |             ) {
86 |                 $part = '' . $part . '';
87 |             }
88 | 
89 |             ++$i;
90 |         }
91 | 
92 |         $rule = implode(' ', $parts);
93 |     }
94 | 
95 |     echo $ruleBlockName, ':', "\n", '      ', implode("\n" . '    | ', $rules), "\n", ';', "\n\n";
96 | }


--------------------------------------------------------------------------------
/grammar/kmyacc.php.parser:
--------------------------------------------------------------------------------
  1 | semValue
  4 | #semval($,%t) $this->semValue
  5 | #semval(%n) $this->semStack[$this->stackPos-(%l-%n)]
  6 | #semval(%n,%t) $this->semStack[$this->stackPos-(%l-%n)]
  7 | #include;
  8 | 
  9 | namespace PhpGenerics;
 10 | use PhpParser\ParserAbstract;
 11 | use PhpParser\Node;
 12 | use PhpParser\Error;
 13 | 
 14 | /* This is an automatically GENERATED file, which should not be manually edited.
 15 |  * Instead edit one of the following:
 16 |  *  * the grammar file grammar/zend_language_parser.phpy
 17 |  *  * the skeleton file grammar/kymacc.php.parser
 18 |  *  * the preprocessing script grammar/rebuildParser.php
 19 |  */
 20 | class Parser extends ParserAbstract
 21 | {
 22 |     protected $tokenToSymbolMapSize = #(YYMAXLEX);
 23 |     protected $actionTableSize = #(YYLAST);
 24 |     protected $gotoTableSize = #(YYGLAST);
 25 | 
 26 |     protected $invalidToken = #(YYBADCH);
 27 |     protected $defaultAction = #(YYDEFAULT);
 28 |     protected $unexpectedTokenRule = #(YYUNEXPECTED);
 29 | 
 30 |     protected $YY2TBLSTATE  = #(YY2TBLSTATE);
 31 |     protected $YYNLSTATES   = #(YYNLSTATES);
 32 | 
 33 | #tokenval
 34 |     const %s = %n;
 35 | #endtokenval
 36 | 
 37 |     protected $symbolToName = array(
 38 |         #listvar terminals
 39 |     );
 40 | 
 41 |     protected $tokenToSymbol = array(
 42 |         #listvar yytranslate
 43 |     );
 44 | 
 45 |     protected $action = array(
 46 |         #listvar yyaction
 47 |     );
 48 | 
 49 |     protected $actionCheck = array(
 50 |         #listvar yycheck
 51 |     );
 52 | 
 53 |     protected $actionBase = array(
 54 |         #listvar yybase
 55 |     );
 56 | 
 57 |     protected $actionDefault = array(
 58 |         #listvar yydefault
 59 |     );
 60 | 
 61 |     protected $goto = array(
 62 |         #listvar yygoto
 63 |     );
 64 | 
 65 |     protected $gotoCheck = array(
 66 |         #listvar yygcheck
 67 |     );
 68 | 
 69 |     protected $gotoBase = array(
 70 |         #listvar yygbase
 71 |     );
 72 | 
 73 |     protected $gotoDefault = array(
 74 |         #listvar yygdefault
 75 |     );
 76 | 
 77 |     protected $ruleToNonTerminal = array(
 78 |         #listvar yylhs
 79 |     );
 80 | 
 81 |     protected $ruleToLength = array(
 82 |         #listvar yylen
 83 |     );
 84 | #if -t
 85 | 
 86 |     protected $productions = array(
 87 |         #production-strings;
 88 |     );
 89 | #endif
 90 | #reduce
 91 | 
 92 |     protected function reduceRule%n($attributes) {
 93 |         %b
 94 |     }
 95 | #noact
 96 | 
 97 |     protected function reduceRule%n() {
 98 |         $this->semValue = $this->semStack[$this->stackPos];
 99 |     }
100 | #endreduce
101 | }
102 | #tailcode;
103 | 


--------------------------------------------------------------------------------
/grammar/rebuildParser.php:
--------------------------------------------------------------------------------
  1 | \'[^\\\\\']*+(?:\\\\.[^\\\\\']*+)*+\')
 25 |     (?"[^\\\\"]*+(?:\\\\.[^\\\\"]*+)*+")
 26 |     (?(?&singleQuotedString)|(?&doubleQuotedString))
 27 |     (?/\*[^*]*+(?:\*(?!/)[^*]*+)*+\*/)
 28 |     (?\{[^\'"/{}]*+(?:(?:(?&string)|(?&comment)|(?&code)|/)[^\'"/{}]*+)*+})
 29 | )';
 30 | 
 31 | const PARAMS = '\[(?[^[\]]*+(?:\[(?¶ms)\][^[\]]*+)*+)\]';
 32 | const ARGS   = '\((?[^()]*+(?:\((?&args)\)[^()]*+)*+)\)';
 33 | 
 34 | ///////////////////
 35 | /// Main script ///
 36 | ///////////////////
 37 | 
 38 | echo 'Building temporary preproprocessed grammar file.', "\n";
 39 | 
 40 | $grammarCode = file_get_contents($grammarFile);
 41 | 
 42 | $grammarCode = resolveConstants($grammarCode);
 43 | $grammarCode = resolveNodes($grammarCode);
 44 | $grammarCode = resolveMacros($grammarCode);
 45 | $grammarCode = resolveArrays($grammarCode);
 46 | 
 47 | file_put_contents($tmpGrammarFile, $grammarCode);
 48 | 
 49 | $additionalArgs = $optionDebug ? '-t -v' : '';
 50 | 
 51 | echo "Building parser.\n";
 52 | $output = trim(shell_exec("$kmyacc $additionalArgs -l -m $skeletonFile $tmpGrammarFile 2>&1"));
 53 | echo "Output: \"$output\"\n";
 54 | 
 55 | moveFileWithDirCheck($tmpResultFile, $parserResultFile);
 56 | 
 57 | if (!$optionKeepTmpGrammar) {
 58 |     unlink($tmpGrammarFile);
 59 | }
 60 | 
 61 | ///////////////////////////////
 62 | /// Preprocessing functions ///
 63 | ///////////////////////////////
 64 | 
 65 | function resolveConstants($code) {
 66 |     return preg_replace('~[A-Z][a-zA-Z_\\\\]++::~', 'Node\\\\$0', $code);
 67 | }
 68 | 
 69 | function resolveNodes($code) {
 70 |     return preg_replace_callback(
 71 |         '~(?[A-Z][a-zA-Z_\\\\]++)\s*' . PARAMS . '~',
 72 |         function($matches) {
 73 |             // recurse
 74 |             $matches['params'] = resolveNodes($matches['params']);
 75 | 
 76 |             $params = magicSplit(
 77 |                 '(?:' . PARAMS . '|' . ARGS . ')(*SKIP)(*FAIL)|,',
 78 |                 $matches['params']
 79 |             );
 80 | 
 81 |             $paramCode = '';
 82 |             foreach ($params as $param) {
 83 |                 $paramCode .= $param . ', ';
 84 |             }
 85 | 
 86 |             return 'new Node\\' . $matches['name'] . '(' . $paramCode . '$attributes)';
 87 |         },
 88 |         $code
 89 |     );
 90 | }
 91 | 
 92 | function resolveMacros($code) {
 93 |     return preg_replace_callback(
 94 |         '~\b(?)(?!array\()(?[a-z][A-Za-z]++)' . ARGS . '~',
 95 |         function($matches) {
 96 |             // recurse
 97 |             $matches['args'] = resolveMacros($matches['args']);
 98 | 
 99 |             $name = $matches['name'];
100 |             $args = magicSplit(
101 |                 '(?:' . PARAMS . '|' . ARGS . ')(*SKIP)(*FAIL)|,',
102 |                 $matches['args']
103 |             );
104 | 
105 |             if ('error' == $name) {
106 |                 assertArgs(1, $args, $name);
107 | 
108 |                 return 'throw new Error(' . $args[0] . ')';
109 |             }
110 | 
111 |             if ('init' == $name) {
112 |                 return '$$ = array(' . implode(', ', $args) . ')';
113 |             }
114 | 
115 |             if ('push' == $name) {
116 |                 assertArgs(2, $args, $name);
117 | 
118 |                 return $args[0] . '[] = ' . $args[1] . '; $$ = ' . $args[0];
119 |             }
120 | 
121 |             if ('pushNormalizing' == $name) {
122 |                 assertArgs(2, $args, $name);
123 | 
124 |                 return 'if (is_array(' . $args[1] . ')) { $$ = array_merge(' . $args[0] . ', ' . $args[1] . '); } else { ' . $args[0] . '[] = ' . $args[1] . '; $$ = ' . $args[0] . '; }';
125 |             }
126 | 
127 |             if ('toArray' == $name) {
128 |                 assertArgs(1, $args, $name);
129 | 
130 |                 return 'is_array(' . $args[0] . ') ? ' . $args[0] . ' : array(' . $args[0] . ')';
131 |             }
132 | 
133 |             if ('parseVar' == $name) {
134 |                 assertArgs(1, $args, $name);
135 | 
136 |                 return 'substr(' . $args[0] . ', 1)';
137 |             }
138 | 
139 |             if ('parseEncapsed' == $name) {
140 |                 assertArgs(2, $args, $name);
141 | 
142 |                 return 'foreach (' . $args[0] . ' as &$s) { if (is_string($s)) { $s = Node\Scalar\String_::parseEscapeSequences($s, ' . $args[1] . '); } }';
143 |             }
144 | 
145 |             if ('parseEncapsedDoc' == $name) {
146 |                 assertArgs(1, $args, $name);
147 | 
148 |                 return 'foreach (' . $args[0] . ' as &$s) { if (is_string($s)) { $s = Node\Scalar\String_::parseEscapeSequences($s, null); } } $s = preg_replace(\'~(\r\n|\n|\r)$~\', \'\', $s); if (\'\' === $s) array_pop(' . $args[0] . ');';
149 |             }
150 | 
151 |             throw new Exception(sprintf('Unknown macro "%s"', $name));
152 |         },
153 |         $code
154 |     );
155 | }
156 | 
157 | function assertArgs($num, $args, $name) {
158 |     if ($num != count($args)) {
159 |         die('Wrong argument count for ' . $name . '().');
160 |     }
161 | }
162 | 
163 | function resolveArrays($code) {
164 |     return preg_replace_callback(
165 |         '~' . PARAMS . '~',
166 |         function ($matches) {
167 |             $elements = magicSplit(
168 |                 '(?:' . PARAMS . '|' . ARGS . ')(*SKIP)(*FAIL)|,',
169 |                 $matches['params']
170 |             );
171 | 
172 |             // don't convert [] to array, it might have different meaning
173 |             if (empty($elements)) {
174 |                 return $matches[0];
175 |             }
176 | 
177 |             $elementCodes = array();
178 |             foreach ($elements as $element) {
179 |                 // convert only arrays where all elements have keys
180 |                 if (false === strpos($element, ':')) {
181 |                     return $matches[0];
182 |                 }
183 | 
184 |                 list($key, $value) = explode(':', $element, 2);
185 |                 $elementCodes[] = "'" . $key . "' =>" . $value;
186 |             }
187 | 
188 |             return 'array(' . implode(', ', $elementCodes) . ')';
189 |         },
190 |         $code
191 |     );
192 | }
193 | 
194 | function moveFileWithDirCheck($fromPath, $toPath) {
195 |     $dir = dirname($toPath);
196 |     if (!is_dir($dir)) {
197 |         mkdir($dir, 0777, true);
198 |     }
199 |     rename($fromPath, $toPath);
200 | }
201 | 
202 | //////////////////////////////
203 | /// Regex helper functions ///
204 | //////////////////////////////
205 | 
206 | function regex($regex) {
207 |     return '~' . LIB . '(?:' . str_replace('~', '\~', $regex) . ')~';
208 | }
209 | 
210 | function magicSplit($regex, $string) {
211 |     $pieces = preg_split(regex('(?:(?&string)|(?&comment)|(?&code))(*SKIP)(*FAIL)|' . $regex), $string);
212 | 
213 |     foreach ($pieces as &$piece) {
214 |         $piece = trim($piece);
215 |     }
216 | 
217 |     return array_filter($pieces);
218 | }
219 | 


--------------------------------------------------------------------------------
/grammar/zend_language_parser.phpy:
--------------------------------------------------------------------------------
  1 | %pure_parser
  2 | %expect 2
  3 | 
  4 | %left T_INCLUDE T_INCLUDE_ONCE T_EVAL T_REQUIRE T_REQUIRE_ONCE
  5 | %left ','
  6 | %left T_LOGICAL_OR
  7 | %left T_LOGICAL_XOR
  8 | %left T_LOGICAL_AND
  9 | %right T_PRINT
 10 | %right T_YIELD
 11 | %left '=' T_PLUS_EQUAL T_MINUS_EQUAL T_MUL_EQUAL T_DIV_EQUAL T_CONCAT_EQUAL T_MOD_EQUAL T_AND_EQUAL T_OR_EQUAL T_XOR_EQUAL T_SL_EQUAL T_SR_EQUAL T_POW_EQUAL
 12 | %left '?' ':'
 13 | %right T_COALESCE
 14 | %left T_BOOLEAN_OR
 15 | %left T_BOOLEAN_AND
 16 | %left '|'
 17 | %left '^'
 18 | %left '&'
 19 | %nonassoc T_IS_EQUAL T_IS_NOT_EQUAL T_IS_IDENTICAL T_IS_NOT_IDENTICAL T_SPACESHIP
 20 | %nonassoc '<' T_IS_SMALLER_OR_EQUAL '>' T_IS_GREATER_OR_EQUAL
 21 | %left T_SL T_SR
 22 | %left '+' '-' '.'
 23 | %left '*' '/' '%'
 24 | %right '!'
 25 | %nonassoc T_INSTANCEOF
 26 | %right '~' T_INC T_DEC T_INT_CAST T_DOUBLE_CAST T_STRING_CAST T_ARRAY_CAST T_OBJECT_CAST T_BOOL_CAST T_UNSET_CAST '@'
 27 | %right T_POW
 28 | %right '['
 29 | %nonassoc T_NEW T_CLONE
 30 | %token T_EXIT
 31 | %token T_IF
 32 | %left T_ELSEIF
 33 | %left T_ELSE
 34 | %left T_ENDIF
 35 | %token T_LNUMBER
 36 | %token T_DNUMBER
 37 | %token T_STRING
 38 | %token T_STRING_VARNAME
 39 | %token T_VARIABLE
 40 | %token T_NUM_STRING
 41 | %token T_INLINE_HTML
 42 | %token T_CHARACTER
 43 | %token T_BAD_CHARACTER
 44 | %token T_ENCAPSED_AND_WHITESPACE
 45 | %token T_CONSTANT_ENCAPSED_STRING
 46 | %token T_ECHO
 47 | %token T_DO
 48 | %token T_WHILE
 49 | %token T_ENDWHILE
 50 | %token T_FOR
 51 | %token T_ENDFOR
 52 | %token T_FOREACH
 53 | %token T_ENDFOREACH
 54 | %token T_DECLARE
 55 | %token T_ENDDECLARE
 56 | %token T_AS
 57 | %token T_SWITCH
 58 | %token T_ENDSWITCH
 59 | %token T_CASE
 60 | %token T_DEFAULT
 61 | %token T_BREAK
 62 | %token T_CONTINUE
 63 | %token T_GOTO
 64 | %token T_FUNCTION
 65 | %token T_CONST
 66 | %token T_RETURN
 67 | %token T_TRY
 68 | %token T_CATCH
 69 | %token T_FINALLY
 70 | %token T_THROW
 71 | %token T_USE
 72 | %token T_INSTEADOF
 73 | %token T_GLOBAL
 74 | %right T_STATIC T_ABSTRACT T_FINAL T_PRIVATE T_PROTECTED T_PUBLIC
 75 | %token T_VAR
 76 | %token T_UNSET
 77 | %token T_ISSET
 78 | %token T_EMPTY
 79 | %token T_HALT_COMPILER
 80 | %token T_CLASS
 81 | %token T_TRAIT
 82 | %token T_INTERFACE
 83 | %token T_EXTENDS
 84 | %token T_IMPLEMENTS
 85 | %token T_OBJECT_OPERATOR
 86 | %token T_DOUBLE_ARROW
 87 | %token T_LIST
 88 | %token T_ARRAY
 89 | %token T_CALLABLE
 90 | %token T_CLASS_C
 91 | %token T_TRAIT_C
 92 | %token T_METHOD_C
 93 | %token T_FUNC_C
 94 | %token T_LINE
 95 | %token T_FILE
 96 | %token T_COMMENT
 97 | %token T_DOC_COMMENT
 98 | %token T_OPEN_TAG
 99 | %token T_OPEN_TAG_WITH_ECHO
100 | %token T_CLOSE_TAG
101 | %token T_WHITESPACE
102 | %token T_START_HEREDOC
103 | %token T_END_HEREDOC
104 | %token T_DOLLAR_OPEN_CURLY_BRACES
105 | %token T_CURLY_OPEN
106 | %token T_PAAMAYIM_NEKUDOTAYIM
107 | %token T_NAMESPACE
108 | %token T_NS_C
109 | %token T_DIR
110 | %token T_NS_SEPARATOR
111 | %token T_ELLIPSIS
112 | 
113 | %%
114 | 
115 | start:
116 |     top_statement_list                                      { $$ = $this->handleNamespaces($1); }
117 | ;
118 | 
119 | top_statement_list:
120 |       top_statement_list top_statement                      { pushNormalizing($1, $2); }
121 |     | /* empty */                                           { init(); }
122 | ;
123 | 
124 | namespace_name_parts:
125 |       T_STRING                                              { init($1); }
126 |     | namespace_name_parts T_NS_SEPARATOR T_STRING          { push($1, $3); }
127 | ;
128 | 
129 | namespace_name:
130 |       namespace_name_parts                                  { $$ = Name[$1]; }
131 | ;
132 | 
133 | top_statement:
134 |       statement                                             { $$ = $1; }
135 |     | function_declaration_statement                        { $$ = $1; }
136 |     | class_declaration_statement                           { $$ = $1; }
137 |     | T_HALT_COMPILER
138 |           { $$ = Stmt\HaltCompiler[$this->lexer->handleHaltCompiler()]; }
139 |     | T_NAMESPACE namespace_name ';'                        { $$ = Stmt\Namespace_[$2, null]; }
140 |     | T_NAMESPACE namespace_name '{' top_statement_list '}' { $$ = Stmt\Namespace_[$2, $4]; }
141 |     | T_NAMESPACE '{' top_statement_list '}'                { $$ = Stmt\Namespace_[null,     $3]; }
142 |     | T_USE use_declarations ';'                            { $$ = Stmt\Use_[$2, Stmt\Use_::TYPE_NORMAL]; }
143 |     | T_USE T_FUNCTION use_declarations ';'                 { $$ = Stmt\Use_[$3, Stmt\Use_::TYPE_FUNCTION]; }
144 |     | T_USE T_CONST use_declarations ';'                    { $$ = Stmt\Use_[$3, Stmt\Use_::TYPE_CONSTANT]; }
145 |     | T_CONST constant_declaration_list ';'                 { $$ = Stmt\Const_[$2]; }
146 | ;
147 | 
148 | use_declarations:
149 |       use_declarations ',' use_declaration                  { push($1, $3); }
150 |     | use_declaration                                       { init($1); }
151 | ;
152 | 
153 | use_declaration:
154 |       namespace_name                                        { $$ = Stmt\UseUse[$1, null]; }
155 |     | namespace_name T_AS T_STRING                          { $$ = Stmt\UseUse[$1, $3]; }
156 |     | T_NS_SEPARATOR namespace_name                         { $$ = Stmt\UseUse[$2, null]; }
157 |     | T_NS_SEPARATOR namespace_name T_AS T_STRING           { $$ = Stmt\UseUse[$2, $4]; }
158 | ;
159 | 
160 | constant_declaration_list:
161 |       constant_declaration_list ',' constant_declaration    { push($1, $3); }
162 |     | constant_declaration                                  { init($1); }
163 | ;
164 | 
165 | constant_declaration:
166 |     T_STRING '=' static_scalar                              { $$ = Const_[$1, $3]; }
167 | ;
168 | 
169 | inner_statement_list:
170 |       inner_statement_list inner_statement                  { pushNormalizing($1, $2); }
171 |     | /* empty */                                           { init(); }
172 | ;
173 | 
174 | inner_statement:
175 |       statement                                             { $$ = $1; }
176 |     | function_declaration_statement                        { $$ = $1; }
177 |     | class_declaration_statement                           { $$ = $1; }
178 |     | T_HALT_COMPILER                                       { error('__HALT_COMPILER() can only be used from the outermost scope'); }
179 | ;
180 | 
181 | statement:
182 |       '{' inner_statement_list '}'                          { $$ = $2; }
183 |     | T_IF parentheses_expr statement elseif_list else_single
184 |           { $$ = Stmt\If_[$2, [stmts: toArray($3), elseifs: $4, else: $5]]; }
185 |     | T_IF parentheses_expr ':' inner_statement_list new_elseif_list new_else_single T_ENDIF ';'
186 |           { $$ = Stmt\If_[$2, [stmts: $4, elseifs: $5, else: $6]]; }
187 |     | T_WHILE parentheses_expr while_statement              { $$ = Stmt\While_[$2, $3]; }
188 |     | T_DO statement T_WHILE parentheses_expr ';'           { $$ = Stmt\Do_   [$4, toArray($2)]; }
189 |     | T_FOR '(' for_expr ';'  for_expr ';' for_expr ')' for_statement
190 |           { $$ = Stmt\For_[[init: $3, cond: $5, loop: $7, stmts: $9]]; }
191 |     | T_SWITCH parentheses_expr switch_case_list            { $$ = Stmt\Switch_[$2, $3]; }
192 |     | T_BREAK ';'                                           { $$ = Stmt\Break_[null]; }
193 |     | T_BREAK expr ';'                                      { $$ = Stmt\Break_[$2]; }
194 |     | T_CONTINUE ';'                                        { $$ = Stmt\Continue_[null]; }
195 |     | T_CONTINUE expr ';'                                   { $$ = Stmt\Continue_[$2]; }
196 |     | T_RETURN ';'                                          { $$ = Stmt\Return_[null]; }
197 |     | T_RETURN expr ';'                                     { $$ = Stmt\Return_[$2]; }
198 |     | yield_expr ';'                                        { $$ = $1; }
199 |     | T_GLOBAL global_var_list ';'                          { $$ = Stmt\Global_[$2]; }
200 |     | T_STATIC static_var_list ';'                          { $$ = Stmt\Static_[$2]; }
201 |     | T_ECHO expr_list ';'                                  { $$ = Stmt\Echo_[$2]; }
202 |     | T_INLINE_HTML                                         { $$ = Stmt\InlineHTML[$1]; }
203 |     | expr ';'                                              { $$ = $1; }
204 |     | T_UNSET '(' variables_list ')' ';'                    { $$ = Stmt\Unset_[$3]; }
205 |     | T_FOREACH '(' expr T_AS foreach_variable ')' foreach_statement
206 |           { $$ = Stmt\Foreach_[$3, $5[0], [keyVar: null, byRef: $5[1], stmts: $7]]; }
207 |     | T_FOREACH '(' expr T_AS variable T_DOUBLE_ARROW foreach_variable ')' foreach_statement
208 |           { $$ = Stmt\Foreach_[$3, $7[0], [keyVar: $5, byRef: $7[1], stmts: $9]]; }
209 |     | T_DECLARE '(' declare_list ')' declare_statement      { $$ = Stmt\Declare_[$3, $5]; }
210 |     | ';'                                                   { $$ = array(); /* means: no statement */ }
211 |     | T_TRY '{' inner_statement_list '}' catches optional_finally
212 |           { $$ = Stmt\TryCatch[$3, $5, $6]; }
213 |     | T_THROW expr ';'                                      { $$ = Stmt\Throw_[$2]; }
214 |     | T_GOTO T_STRING ';'                                   { $$ = Stmt\Goto_[$2]; }
215 |     | T_STRING ':'                                          { $$ = Stmt\Label[$1]; }
216 | ;
217 | 
218 | catches:
219 |       /* empty */                                           { init(); }
220 |     | catches catch                                         { push($1, $2); }
221 | ;
222 | 
223 | catch:
224 |     T_CATCH '(' name T_VARIABLE ')' '{' inner_statement_list '}'
225 |         { $$ = Stmt\Catch_[$3, parseVar($4), $7]; }
226 | ;
227 | 
228 | optional_finally:
229 |       /* empty */                                           { $$ = null; }
230 |     | T_FINALLY '{' inner_statement_list '}'                { $$ = $3; }
231 | ;
232 | 
233 | variables_list:
234 |       variable                                              { init($1); }
235 |     | variables_list ',' variable                           { push($1, $3); }
236 | ;
237 | 
238 | optional_ref:
239 |       /* empty */                                           { $$ = false; }
240 |     | '&'                                                   { $$ = true; }
241 | ;
242 | 
243 | optional_ellipsis:
244 |       /* empty */                                           { $$ = false; }
245 |     | T_ELLIPSIS                                            { $$ = true; }
246 | ;
247 | 
248 | function_declaration_statement:
249 |     T_FUNCTION optional_ref T_STRING generics '(' parameter_list ')' optional_return_type '{' inner_statement_list '}'
250 |         { $$ = Stmt\Function_[$3, [byRef: $2, params: $6, returnType: $8, stmts: $10], [generics: $4]]; }
251 | ;
252 | 
253 | class_declaration_statement:
254 |       class_entry_type T_STRING generics extends_from implements_list '{' class_statement_list '}'
255 |           { $$ = Stmt\Class_[$2, [type: $1, extends: $4, implements: $5, stmts: $7], [generics: $3]]; }
256 |     | T_INTERFACE T_STRING generics interface_extends_list '{' class_statement_list '}'
257 |           { $$ = Stmt\Interface_[$2, [extends: $4, stmts: $6], [generics: $3]]; }
258 |     | T_TRAIT T_STRING generics '{' class_statement_list '}'
259 |           { $$ = Stmt\Trait_[$2, $5, [generics: $3]]; }
260 | ;
261 | 
262 | generics:
263 | 	  /* empty */											{ $$ = null; }
264 | 	| '<' '>'												{ $$ = null; }
265 | 	| '<' non_empty_generic_types '>'						{ $$ = $2; }
266 | ;
267 | 
268 | non_empty_generic_types:
269 | 	  T_STRING												{ init($1); }
270 | 	| non_empty_generic_types ',' T_STRING					{ push($1, $3); }
271 | ;
272 | 
273 | class_entry_type:
274 |       T_CLASS                                               { $$ = 0; }
275 |     | T_ABSTRACT T_CLASS                                    { $$ = Stmt\Class_::MODIFIER_ABSTRACT; }
276 |     | T_FINAL T_CLASS                                       { $$ = Stmt\Class_::MODIFIER_FINAL; }
277 | ;
278 | 
279 | extends_from:
280 |       /* empty */                                           { $$ = null; }
281 |     | T_EXTENDS name                                        { $$ = $2; }
282 | ;
283 | 
284 | interface_extends_list:
285 |       /* empty */                                           { $$ = array(); }
286 |     | T_EXTENDS name_list                                   { $$ = $2; }
287 | ;
288 | 
289 | implements_list:
290 |       /* empty */                                           { $$ = array(); }
291 |     | T_IMPLEMENTS name_list                                { $$ = $2; }
292 | ;
293 | 
294 | name_list:
295 |       name                                                  { init($1); }
296 |     | name_list ',' name                                    { push($1, $3); }
297 | ;
298 | 
299 | for_statement:
300 |       statement                                             { $$ = toArray($1); }
301 |     | ':' inner_statement_list T_ENDFOR ';'                 { $$ = $2; }
302 | ;
303 | 
304 | foreach_statement:
305 |       statement                                             { $$ = toArray($1); }
306 |     | ':' inner_statement_list T_ENDFOREACH ';'             { $$ = $2; }
307 | ;
308 | 
309 | declare_statement:
310 |       statement                                             { $$ = toArray($1); }
311 |     | ':' inner_statement_list T_ENDDECLARE ';'             { $$ = $2; }
312 | ;
313 | 
314 | declare_list:
315 |       declare_list_element                                  { init($1); }
316 |     | declare_list ',' declare_list_element                 { push($1, $3); }
317 | ;
318 | 
319 | declare_list_element:
320 |       T_STRING '=' static_scalar                            { $$ = Stmt\DeclareDeclare[$1, $3]; }
321 | ;
322 | 
323 | switch_case_list:
324 |       '{' case_list '}'                                     { $$ = $2; }
325 |     | '{' ';' case_list '}'                                 { $$ = $3; }
326 |     | ':' case_list T_ENDSWITCH ';'                         { $$ = $2; }
327 |     | ':' ';' case_list T_ENDSWITCH ';'                     { $$ = $3; }
328 | ;
329 | 
330 | case_list:
331 |       /* empty */                                           { init(); }
332 |     | case_list case                                        { push($1, $2); }
333 | ;
334 | 
335 | case:
336 |       T_CASE expr case_separator inner_statement_list       { $$ = Stmt\Case_[$2, $4]; }
337 |     | T_DEFAULT case_separator inner_statement_list         { $$ = Stmt\Case_[null, $3]; }
338 | ;
339 | 
340 | case_separator:
341 |       ':'
342 |     | ';'
343 | ;
344 | 
345 | while_statement:
346 |       statement                                             { $$ = toArray($1); }
347 |     | ':' inner_statement_list T_ENDWHILE ';'               { $$ = $2; }
348 | ;
349 | 
350 | elseif_list:
351 |       /* empty */                                           { init(); }
352 |     | elseif_list elseif                                    { push($1, $2); }
353 | ;
354 | 
355 | elseif:
356 |       T_ELSEIF parentheses_expr statement                   { $$ = Stmt\ElseIf_[$2, toArray($3)]; }
357 | ;
358 | 
359 | new_elseif_list:
360 |       /* empty */                                           { init(); }
361 |     | new_elseif_list new_elseif                            { push($1, $2); }
362 | ;
363 | 
364 | new_elseif:
365 |      T_ELSEIF parentheses_expr ':' inner_statement_list     { $$ = Stmt\ElseIf_[$2, $4]; }
366 | ;
367 | 
368 | else_single:
369 |       /* empty */                                           { $$ = null; }
370 |     | T_ELSE statement                                      { $$ = Stmt\Else_[toArray($2)]; }
371 | ;
372 | 
373 | new_else_single:
374 |       /* empty */                                           { $$ = null; }
375 |     | T_ELSE ':' inner_statement_list                       { $$ = Stmt\Else_[$3]; }
376 | ;
377 | 
378 | foreach_variable:
379 |       variable                                              { $$ = array($1, false); }
380 |     | '&' variable                                          { $$ = array($2, true); }
381 |     | list_expr                                             { $$ = array($1, false); }
382 | ;
383 | 
384 | parameter_list:
385 |       non_empty_parameter_list                              { $$ = $1; }
386 |     | /* empty */                                           { $$ = array(); }
387 | ;
388 | 
389 | non_empty_parameter_list:
390 |       parameter                                             { init($1); }
391 |     | non_empty_parameter_list ',' parameter                { push($1, $3); }
392 | ;
393 | 
394 | parameter:
395 |       optional_param_type optional_ref optional_ellipsis T_VARIABLE
396 |           { $$ = Param[parseVar($4), null, $1, $2, $3]; }
397 |     | optional_param_type optional_ref optional_ellipsis T_VARIABLE '=' static_scalar
398 |           { $$ = Param[parseVar($4), $6, $1, $2, $3]; }
399 | ;
400 | 
401 | type:
402 |       name generics                                         { $$ = $1; $1->setAttribute("generics", $2); }
403 |     | T_ARRAY                                               { $$ = 'array'; }
404 |     | T_CALLABLE                                            { $$ = 'callable'; }
405 | ;
406 | 
407 | optional_param_type:
408 |       /* empty */                                           { $$ = null; }
409 |     | type                                                  { $$ = $1; }
410 | ;
411 | 
412 | optional_return_type:
413 |       /* empty */                                           { $$ = null; }
414 |     | ':' type                                              { $$ = $2; }
415 | ;
416 | 
417 | argument_list:
418 |       '(' ')'                                               { $$ = array(); }
419 |     | '(' non_empty_argument_list ')'                       { $$ = $2; }
420 |     | '(' yield_expr ')'                                    { $$ = array(Arg[$2, false, false]); }
421 | ;
422 | 
423 | non_empty_argument_list:
424 |       argument                                              { init($1); }
425 |     | non_empty_argument_list ',' argument                  { push($1, $3); }
426 | ;
427 | 
428 | argument:
429 |       expr                                                  { $$ = Arg[$1, false, false]; }
430 |     | '&' variable                                          { $$ = Arg[$2, true, false]; }
431 |     | T_ELLIPSIS expr                                       { $$ = Arg[$2, false, true]; }
432 | ;
433 | 
434 | global_var_list:
435 |       global_var_list ',' global_var                        { push($1, $3); }
436 |     | global_var                                            { init($1); }
437 | ;
438 | 
439 | global_var:
440 |       T_VARIABLE                                            { $$ = Expr\Variable[parseVar($1)]; }
441 |     | '$' variable                                          { $$ = Expr\Variable[$2]; }
442 |     | '$' '{' expr '}'                                      { $$ = Expr\Variable[$3]; }
443 | ;
444 | 
445 | static_var_list:
446 |       static_var_list ',' static_var                        { push($1, $3); }
447 |     | static_var                                            { init($1); }
448 | ;
449 | 
450 | static_var:
451 |       T_VARIABLE                                            { $$ = Stmt\StaticVar[parseVar($1), null]; }
452 |     | T_VARIABLE '=' static_scalar                          { $$ = Stmt\StaticVar[parseVar($1), $3]; }
453 | ;
454 | 
455 | class_statement_list:
456 |       class_statement_list class_statement                  { push($1, $2); }
457 |     | /* empty */                                           { init(); }
458 | ;
459 | 
460 | class_statement:
461 |       variable_modifiers property_declaration_list ';'      { $$ = Stmt\Property[$1, $2]; }
462 |     | T_CONST constant_declaration_list ';'                 { $$ = Stmt\ClassConst[$2]; }
463 |     | method_modifiers T_FUNCTION optional_ref T_STRING generics '(' parameter_list ')' optional_return_type method_body
464 |           { $$ = Stmt\ClassMethod[$4, [type: $1, byRef: $3, params: $7, returnType: $9, stmts: $10], [generics: $5]]; }
465 |     | T_USE name_list trait_adaptations                     { $$ = Stmt\TraitUse[$2, $3]; }
466 | ;
467 | 
468 | trait_adaptations:
469 |       ';'                                                   { $$ = array(); }
470 |     | '{' trait_adaptation_list '}'                         { $$ = $2; }
471 | ;
472 | 
473 | trait_adaptation_list:
474 |       /* empty */                                           { init(); }
475 |     | trait_adaptation_list trait_adaptation                { push($1, $2); }
476 | ;
477 | 
478 | trait_adaptation:
479 |       trait_method_reference_fully_qualified T_INSTEADOF name_list ';'
480 |           { $$ = Stmt\TraitUseAdaptation\Precedence[$1[0], $1[1], $3]; }
481 |     | trait_method_reference T_AS member_modifier T_STRING ';'
482 |           { $$ = Stmt\TraitUseAdaptation\Alias[$1[0], $1[1], $3, $4]; }
483 |     | trait_method_reference T_AS member_modifier ';'
484 |           { $$ = Stmt\TraitUseAdaptation\Alias[$1[0], $1[1], $3, null]; }
485 |     | trait_method_reference T_AS T_STRING ';'
486 |           { $$ = Stmt\TraitUseAdaptation\Alias[$1[0], $1[1], null, $3]; }
487 | ;
488 | 
489 | trait_method_reference_fully_qualified:
490 |       name T_PAAMAYIM_NEKUDOTAYIM T_STRING                  { $$ = array($1, $3); }
491 | ;
492 | trait_method_reference:
493 |       trait_method_reference_fully_qualified                { $$ = $1; }
494 |     | T_STRING                                              { $$ = array(null, $1); }
495 | ;
496 | 
497 | method_body:
498 |       ';' /* abstract method */                             { $$ = null; }
499 |     | '{' inner_statement_list '}'                          { $$ = $2; }
500 | ;
501 | 
502 | variable_modifiers:
503 |       non_empty_member_modifiers                            { $$ = $1; }
504 |     | T_VAR                                                 { $$ = 0; }
505 | ;
506 | 
507 | method_modifiers:
508 |       /* empty */                                           { $$ = 0; }
509 |     | non_empty_member_modifiers                            { $$ = $1; }
510 | ;
511 | 
512 | non_empty_member_modifiers:
513 |       member_modifier                                       { $$ = $1; }
514 |     | non_empty_member_modifiers member_modifier            { Stmt\Class_::verifyModifier($1, $2); $$ = $1 | $2; }
515 | ;
516 | 
517 | member_modifier:
518 |       T_PUBLIC                                              { $$ = Stmt\Class_::MODIFIER_PUBLIC; }
519 |     | T_PROTECTED                                           { $$ = Stmt\Class_::MODIFIER_PROTECTED; }
520 |     | T_PRIVATE                                             { $$ = Stmt\Class_::MODIFIER_PRIVATE; }
521 |     | T_STATIC                                              { $$ = Stmt\Class_::MODIFIER_STATIC; }
522 |     | T_ABSTRACT                                            { $$ = Stmt\Class_::MODIFIER_ABSTRACT; }
523 |     | T_FINAL                                               { $$ = Stmt\Class_::MODIFIER_FINAL; }
524 | ;
525 | 
526 | property_declaration_list:
527 |       property_declaration                                  { init($1); }
528 |     | property_declaration_list ',' property_declaration    { push($1, $3); }
529 | ;
530 | 
531 | property_declaration:
532 |       T_VARIABLE                                            { $$ = Stmt\PropertyProperty[parseVar($1), null]; }
533 |     | T_VARIABLE '=' static_scalar                          { $$ = Stmt\PropertyProperty[parseVar($1), $3]; }
534 | ;
535 | 
536 | expr_list:
537 |       expr_list ',' expr                                    { push($1, $3); }
538 |     | expr                                                  { init($1); }
539 | ;
540 | 
541 | for_expr:
542 |       /* empty */                                           { $$ = array(); }
543 |     | expr_list                                             { $$ = $1; }
544 | ;
545 | 
546 | expr:
547 |       variable                                              { $$ = $1; }
548 |     | list_expr '=' expr                                    { $$ = Expr\Assign[$1, $3]; }
549 |     | variable '=' expr                                     { $$ = Expr\Assign[$1, $3]; }
550 |     | variable '=' '&' variable                             { $$ = Expr\AssignRef[$1, $4]; }
551 |     | variable '=' '&' new_expr                             { $$ = Expr\AssignRef[$1, $4]; }
552 |     | new_expr                                              { $$ = $1; }
553 |     | T_CLONE expr                                          { $$ = Expr\Clone_[$2]; }
554 |     | variable T_PLUS_EQUAL expr                            { $$ = Expr\AssignOp\Plus      [$1, $3]; }
555 |     | variable T_MINUS_EQUAL expr                           { $$ = Expr\AssignOp\Minus     [$1, $3]; }
556 |     | variable T_MUL_EQUAL expr                             { $$ = Expr\AssignOp\Mul       [$1, $3]; }
557 |     | variable T_DIV_EQUAL expr                             { $$ = Expr\AssignOp\Div       [$1, $3]; }
558 |     | variable T_CONCAT_EQUAL expr                          { $$ = Expr\AssignOp\Concat    [$1, $3]; }
559 |     | variable T_MOD_EQUAL expr                             { $$ = Expr\AssignOp\Mod       [$1, $3]; }
560 |     | variable T_AND_EQUAL expr                             { $$ = Expr\AssignOp\BitwiseAnd[$1, $3]; }
561 |     | variable T_OR_EQUAL expr                              { $$ = Expr\AssignOp\BitwiseOr [$1, $3]; }
562 |     | variable T_XOR_EQUAL expr                             { $$ = Expr\AssignOp\BitwiseXor[$1, $3]; }
563 |     | variable T_SL_EQUAL expr                              { $$ = Expr\AssignOp\ShiftLeft [$1, $3]; }
564 |     | variable T_SR_EQUAL expr                              { $$ = Expr\AssignOp\ShiftRight[$1, $3]; }
565 |     | variable T_POW_EQUAL expr                             { $$ = Expr\AssignOp\Pow       [$1, $3]; }
566 |     | variable T_INC                                        { $$ = Expr\PostInc[$1]; }
567 |     | T_INC variable                                        { $$ = Expr\PreInc [$2]; }
568 |     | variable T_DEC                                        { $$ = Expr\PostDec[$1]; }
569 |     | T_DEC variable                                        { $$ = Expr\PreDec [$2]; }
570 |     | expr T_BOOLEAN_OR expr                                { $$ = Expr\BinaryOp\BooleanOr [$1, $3]; }
571 |     | expr T_BOOLEAN_AND expr                               { $$ = Expr\BinaryOp\BooleanAnd[$1, $3]; }
572 |     | expr T_LOGICAL_OR expr                                { $$ = Expr\BinaryOp\LogicalOr [$1, $3]; }
573 |     | expr T_LOGICAL_AND expr                               { $$ = Expr\BinaryOp\LogicalAnd[$1, $3]; }
574 |     | expr T_LOGICAL_XOR expr                               { $$ = Expr\BinaryOp\LogicalXor[$1, $3]; }
575 |     | expr '|' expr                                         { $$ = Expr\BinaryOp\BitwiseOr [$1, $3]; }
576 |     | expr '&' expr                                         { $$ = Expr\BinaryOp\BitwiseAnd[$1, $3]; }
577 |     | expr '^' expr                                         { $$ = Expr\BinaryOp\BitwiseXor[$1, $3]; }
578 |     | expr '.' expr                                         { $$ = Expr\BinaryOp\Concat    [$1, $3]; }
579 |     | expr '+' expr                                         { $$ = Expr\BinaryOp\Plus      [$1, $3]; }
580 |     | expr '-' expr                                         { $$ = Expr\BinaryOp\Minus     [$1, $3]; }
581 |     | expr '*' expr                                         { $$ = Expr\BinaryOp\Mul       [$1, $3]; }
582 |     | expr '/' expr                                         { $$ = Expr\BinaryOp\Div       [$1, $3]; }
583 |     | expr '%' expr                                         { $$ = Expr\BinaryOp\Mod       [$1, $3]; }
584 |     | expr T_SL expr                                        { $$ = Expr\BinaryOp\ShiftLeft [$1, $3]; }
585 |     | expr T_SR expr                                        { $$ = Expr\BinaryOp\ShiftRight[$1, $3]; }
586 |     | expr T_POW expr                                       { $$ = Expr\BinaryOp\Pow       [$1, $3]; }
587 |     | '+' expr %prec T_INC                                  { $$ = Expr\UnaryPlus [$2]; }
588 |     | '-' expr %prec T_INC                                  { $$ = Expr\UnaryMinus[$2]; }
589 |     | '!' expr                                              { $$ = Expr\BooleanNot[$2]; }
590 |     | '~' expr                                              { $$ = Expr\BitwiseNot[$2]; }
591 |     | expr T_IS_IDENTICAL expr                              { $$ = Expr\BinaryOp\Identical     [$1, $3]; }
592 |     | expr T_IS_NOT_IDENTICAL expr                          { $$ = Expr\BinaryOp\NotIdentical  [$1, $3]; }
593 |     | expr T_IS_EQUAL expr                                  { $$ = Expr\BinaryOp\Equal         [$1, $3]; }
594 |     | expr T_IS_NOT_EQUAL expr                              { $$ = Expr\BinaryOp\NotEqual      [$1, $3]; }
595 |     | expr T_SPACESHIP expr                                 { $$ = Expr\BinaryOp\Spaceship     [$1, $3]; }
596 |     | expr '<' expr                                         { $$ = Expr\BinaryOp\Smaller       [$1, $3]; }
597 |     | expr T_IS_SMALLER_OR_EQUAL expr                       { $$ = Expr\BinaryOp\SmallerOrEqual[$1, $3]; }
598 |     | expr '>' expr                                         { $$ = Expr\BinaryOp\Greater       [$1, $3]; }
599 |     | expr T_IS_GREATER_OR_EQUAL expr                       { $$ = Expr\BinaryOp\GreaterOrEqual[$1, $3]; }
600 |     | expr T_INSTANCEOF class_name_reference                { $$ = Expr\Instanceof_[$1, $3]; }
601 |     | parentheses_expr                                      { $$ = $1; }
602 |     /* we need a separate '(' new_expr ')' rule to avoid problems caused by a s/r conflict */
603 |     | '(' new_expr ')'                                      { $$ = $2; }
604 |     | expr '?' expr ':' expr                                { $$ = Expr\Ternary[$1, $3,   $5]; }
605 |     | expr '?' ':' expr                                     { $$ = Expr\Ternary[$1, null, $4]; }
606 |     | expr T_COALESCE expr                                  { $$ = Expr\BinaryOp\Coalesce[$1, $3]; }
607 |     | T_ISSET '(' variables_list ')'                        { $$ = Expr\Isset_[$3]; }
608 |     | T_EMPTY '(' expr ')'                                  { $$ = Expr\Empty_[$3]; }
609 |     | T_INCLUDE expr                                        { $$ = Expr\Include_[$2, Expr\Include_::TYPE_INCLUDE]; }
610 |     | T_INCLUDE_ONCE expr                                   { $$ = Expr\Include_[$2, Expr\Include_::TYPE_INCLUDE_ONCE]; }
611 |     | T_EVAL parentheses_expr                               { $$ = Expr\Eval_[$2]; }
612 |     | T_REQUIRE expr                                        { $$ = Expr\Include_[$2, Expr\Include_::TYPE_REQUIRE]; }
613 |     | T_REQUIRE_ONCE expr                                   { $$ = Expr\Include_[$2, Expr\Include_::TYPE_REQUIRE_ONCE]; }
614 |     | T_INT_CAST expr                                       { $$ = Expr\Cast\Int_    [$2]; }
615 |     | T_DOUBLE_CAST expr                                    { $$ = Expr\Cast\Double  [$2]; }
616 |     | T_STRING_CAST expr                                    { $$ = Expr\Cast\String_ [$2]; }
617 |     | T_ARRAY_CAST expr                                     { $$ = Expr\Cast\Array_  [$2]; }
618 |     | T_OBJECT_CAST expr                                    { $$ = Expr\Cast\Object_ [$2]; }
619 |     | T_BOOL_CAST expr                                      { $$ = Expr\Cast\Bool_   [$2]; }
620 |     | T_UNSET_CAST expr                                     { $$ = Expr\Cast\Unset_  [$2]; }
621 |     | T_EXIT exit_expr                                      { $$ = Expr\Exit_        [$2]; }
622 |     | '@' expr                                              { $$ = Expr\ErrorSuppress[$2]; }
623 |     | scalar                                                { $$ = $1; }
624 |     | array_expr                                            { $$ = $1; }
625 |     | scalar_dereference                                    { $$ = $1; }
626 |     | '`' backticks_expr '`'                                { $$ = Expr\ShellExec[$2]; }
627 |     | T_PRINT expr                                          { $$ = Expr\Print_[$2]; }
628 |     | T_YIELD                                               { $$ = Expr\Yield_[null, null]; }
629 |     | T_FUNCTION optional_ref '(' parameter_list ')' lexical_vars optional_return_type
630 |       '{' inner_statement_list '}'
631 |           { $$ = Expr\Closure[[static: false, byRef: $2, params: $4, uses: $6, returnType: $7, stmts: $9]]; }
632 |     | T_STATIC T_FUNCTION optional_ref '(' parameter_list ')' lexical_vars optional_return_type
633 |       '{' inner_statement_list '}'
634 |           { $$ = Expr\Closure[[static: true, byRef: $3, params: $5, uses: $7, returnType: $8, stmts: $10]]; }
635 | ;
636 | 
637 | parentheses_expr:
638 |       '(' expr ')'                                          { $$ = $2; }
639 |     | '(' yield_expr ')'                                    { $$ = $2; }
640 | ;
641 | 
642 | yield_expr:
643 |       T_YIELD expr                                          { $$ = Expr\Yield_[$2, null]; }
644 |     | T_YIELD expr T_DOUBLE_ARROW expr                      { $$ = Expr\Yield_[$4, $2]; }
645 | ;
646 | 
647 | array_expr:
648 |       T_ARRAY '(' array_pair_list ')'                       { $$ = Expr\Array_[$3]; }
649 |     | '[' array_pair_list ']'                               { $$ = Expr\Array_[$2]; }
650 | ;
651 | 
652 | scalar_dereference:
653 |       array_expr '[' dim_offset ']'                         { $$ = Expr\ArrayDimFetch[$1, $3]; }
654 |     | T_CONSTANT_ENCAPSED_STRING '[' dim_offset ']'
655 |           { $$ = Expr\ArrayDimFetch[Scalar\String_[Scalar\String_::parse($1)], $3]; }
656 |     | constant '[' dim_offset ']'                           { $$ = Expr\ArrayDimFetch[$1, $3]; }
657 |     | scalar_dereference '[' dim_offset ']'                 { $$ = Expr\ArrayDimFetch[$1, $3]; }
658 |     /* alternative array syntax missing intentionally */
659 | ;
660 | 
661 | new_expr:
662 |       T_NEW class_name_reference generics ctor_arguments             { $$ = Expr\New_[$2, $4, [generics: $3]]; }
663 | ;
664 | 
665 | lexical_vars:
666 |       /* empty */                                           { $$ = array(); }
667 |     | T_USE '(' lexical_var_list ')'                        { $$ = $3; }
668 | ;
669 | 
670 | lexical_var_list:
671 |       lexical_var                                           { init($1); }
672 |     | lexical_var_list ',' lexical_var                      { push($1, $3); }
673 | ;
674 | 
675 | lexical_var:
676 |       optional_ref T_VARIABLE                               { $$ = Expr\ClosureUse[parseVar($2), $1]; }
677 | ;
678 | 
679 | function_call:
680 |       name generics argument_list                                    { $$ = Expr\FuncCall[$1, $3, [generics: $2]]; }
681 |     | class_name_or_var T_PAAMAYIM_NEKUDOTAYIM T_STRING generics argument_list
682 |           { $$ = Expr\StaticCall[$1, $3, $5, [generics: $4]]; }
683 |     | class_name_or_var T_PAAMAYIM_NEKUDOTAYIM '{' expr '}' generics argument_list
684 |           { $$ = Expr\StaticCall[$1, $4, $7, [generics: $6]]; }
685 |     | static_property argument_list {
686 |             if ($1 instanceof Node\Expr\StaticPropertyFetch) {
687 |                 $$ = Expr\StaticCall[$1->class, Expr\Variable[$1->name], $2];
688 |             } elseif ($1 instanceof Node\Expr\ArrayDimFetch) {
689 |                 $tmp = $1;
690 |                 while ($tmp->var instanceof Node\Expr\ArrayDimFetch) {
691 |                     $tmp = $tmp->var;
692 |                 }
693 | 
694 |                 $$ = Expr\StaticCall[$tmp->var->class, $1, $2];
695 |                 $tmp->var = Expr\Variable[$tmp->var->name];
696 |             } else {
697 |                 throw new \Exception;
698 |             }
699 |           }
700 |     | variable_without_objects argument_list
701 |           { $$ = Expr\FuncCall[$1, $2]; }
702 |     | function_call '[' dim_offset ']'                      { $$ = Expr\ArrayDimFetch[$1, $3]; }
703 |       /* alternative array syntax missing intentionally */
704 | ;
705 | 
706 | class_name:
707 |       T_STATIC                                              { $$ = Name[$1]; }
708 |     | name                                                  { $$ = $1; }
709 | ;
710 | 
711 | name:
712 |       namespace_name_parts                                  { $$ = Name[$1]; }
713 |     | T_NS_SEPARATOR namespace_name_parts                   { $$ = Name\FullyQualified[$2]; }
714 |     | T_NAMESPACE T_NS_SEPARATOR namespace_name_parts       { $$ = Name\Relative[$3]; }
715 | ;
716 | 
717 | class_name_reference:
718 |       class_name                                            { $$ = $1; }
719 |     | dynamic_class_name_reference                          { $$ = $1; }
720 | ;
721 | 
722 | dynamic_class_name_reference:
723 |       object_access_for_dcnr                                { $$ = $1; }
724 |     | base_variable                                         { $$ = $1; }
725 | ;
726 | 
727 | class_name_or_var:
728 |       class_name                                            { $$ = $1; }
729 |     | reference_variable                                    { $$ = $1; }
730 | ;
731 | 
732 | object_access_for_dcnr:
733 |       base_variable T_OBJECT_OPERATOR object_property
734 |           { $$ = Expr\PropertyFetch[$1, $3]; }
735 |     | object_access_for_dcnr T_OBJECT_OPERATOR object_property
736 |           { $$ = Expr\PropertyFetch[$1, $3]; }
737 |     | object_access_for_dcnr '[' dim_offset ']'             { $$ = Expr\ArrayDimFetch[$1, $3]; }
738 |     | object_access_for_dcnr '{' expr '}'                   { $$ = Expr\ArrayDimFetch[$1, $3]; }
739 | ;
740 | 
741 | exit_expr:
742 |       /* empty */                                           { $$ = null; }
743 |     | '(' ')'                                               { $$ = null; }
744 |     | parentheses_expr                                      { $$ = $1; }
745 | ;
746 | 
747 | backticks_expr:
748 |       /* empty */                                           { $$ = array(); }
749 |     | T_ENCAPSED_AND_WHITESPACE                             { $$ = array(Scalar\String_::parseEscapeSequences($1, '`')); }
750 |     | encaps_list                                           { parseEncapsed($1, '`'); $$ = $1; }
751 | ;
752 | 
753 | ctor_arguments:
754 |       /* empty */                                           { $$ = array(); }
755 |     | argument_list                                         { $$ = $1; }
756 | ;
757 | 
758 | common_scalar:
759 |       T_LNUMBER                                             { $$ = Scalar\LNumber[Scalar\LNumber::parse($1)]; }
760 |     | T_DNUMBER                                             { $$ = Scalar\DNumber[Scalar\DNumber::parse($1)]; }
761 |     | T_CONSTANT_ENCAPSED_STRING                            { $$ = Scalar\String_[Scalar\String_::parse($1)]; }
762 |     | T_LINE                                                { $$ = Scalar\MagicConst\Line[]; }
763 |     | T_FILE                                                { $$ = Scalar\MagicConst\File[]; }
764 |     | T_DIR                                                 { $$ = Scalar\MagicConst\Dir[]; }
765 |     | T_CLASS_C                                             { $$ = Scalar\MagicConst\Class_[]; }
766 |     | T_TRAIT_C                                             { $$ = Scalar\MagicConst\Trait_[]; }
767 |     | T_METHOD_C                                            { $$ = Scalar\MagicConst\Method[]; }
768 |     | T_FUNC_C                                              { $$ = Scalar\MagicConst\Function_[]; }
769 |     | T_NS_C                                                { $$ = Scalar\MagicConst\Namespace_[]; }
770 |     | T_START_HEREDOC T_ENCAPSED_AND_WHITESPACE T_END_HEREDOC
771 |           { $$ = Scalar\String_[Scalar\String_::parseDocString($1, $2)]; }
772 |     | T_START_HEREDOC T_END_HEREDOC
773 |           { $$ = Scalar\String_['']; }
774 | ;
775 | 
776 | static_scalar:
777 |       common_scalar                                         { $$ = $1; }
778 |     | class_name T_PAAMAYIM_NEKUDOTAYIM class_const_name    { $$ = Expr\ClassConstFetch[$1, $3]; }
779 |     | name                                                  { $$ = Expr\ConstFetch[$1]; }
780 |     | T_ARRAY '(' static_array_pair_list ')'                { $$ = Expr\Array_[$3]; }
781 |     | '[' static_array_pair_list ']'                        { $$ = Expr\Array_[$2]; }
782 |     | static_operation                                      { $$ = $1; }
783 | ;
784 | 
785 | static_operation:
786 |       static_scalar T_BOOLEAN_OR static_scalar              { $$ = Expr\BinaryOp\BooleanOr [$1, $3]; }
787 |     | static_scalar T_BOOLEAN_AND static_scalar             { $$ = Expr\BinaryOp\BooleanAnd[$1, $3]; }
788 |     | static_scalar T_LOGICAL_OR static_scalar              { $$ = Expr\BinaryOp\LogicalOr [$1, $3]; }
789 |     | static_scalar T_LOGICAL_AND static_scalar             { $$ = Expr\BinaryOp\LogicalAnd[$1, $3]; }
790 |     | static_scalar T_LOGICAL_XOR static_scalar             { $$ = Expr\BinaryOp\LogicalXor[$1, $3]; }
791 |     | static_scalar '|' static_scalar                       { $$ = Expr\BinaryOp\BitwiseOr [$1, $3]; }
792 |     | static_scalar '&' static_scalar                       { $$ = Expr\BinaryOp\BitwiseAnd[$1, $3]; }
793 |     | static_scalar '^' static_scalar                       { $$ = Expr\BinaryOp\BitwiseXor[$1, $3]; }
794 |     | static_scalar '.' static_scalar                       { $$ = Expr\BinaryOp\Concat    [$1, $3]; }
795 |     | static_scalar '+' static_scalar                       { $$ = Expr\BinaryOp\Plus      [$1, $3]; }
796 |     | static_scalar '-' static_scalar                       { $$ = Expr\BinaryOp\Minus     [$1, $3]; }
797 |     | static_scalar '*' static_scalar                       { $$ = Expr\BinaryOp\Mul       [$1, $3]; }
798 |     | static_scalar '/' static_scalar                       { $$ = Expr\BinaryOp\Div       [$1, $3]; }
799 |     | static_scalar '%' static_scalar                       { $$ = Expr\BinaryOp\Mod       [$1, $3]; }
800 |     | static_scalar T_SL static_scalar                      { $$ = Expr\BinaryOp\ShiftLeft [$1, $3]; }
801 |     | static_scalar T_SR static_scalar                      { $$ = Expr\BinaryOp\ShiftRight[$1, $3]; }
802 |     | static_scalar T_POW static_scalar                     { $$ = Expr\BinaryOp\Pow       [$1, $3]; }
803 |     | '+' static_scalar %prec T_INC                         { $$ = Expr\UnaryPlus [$2]; }
804 |     | '-' static_scalar %prec T_INC                         { $$ = Expr\UnaryMinus[$2]; }
805 |     | '!' static_scalar                                     { $$ = Expr\BooleanNot[$2]; }
806 |     | '~' static_scalar                                     { $$ = Expr\BitwiseNot[$2]; }
807 |     | static_scalar T_IS_IDENTICAL static_scalar            { $$ = Expr\BinaryOp\Identical     [$1, $3]; }
808 |     | static_scalar T_IS_NOT_IDENTICAL static_scalar        { $$ = Expr\BinaryOp\NotIdentical  [$1, $3]; }
809 |     | static_scalar T_IS_EQUAL static_scalar                { $$ = Expr\BinaryOp\Equal         [$1, $3]; }
810 |     | static_scalar T_IS_NOT_EQUAL static_scalar            { $$ = Expr\BinaryOp\NotEqual      [$1, $3]; }
811 |     | static_scalar '<' static_scalar                       { $$ = Expr\BinaryOp\Smaller       [$1, $3]; }
812 |     | static_scalar T_IS_SMALLER_OR_EQUAL static_scalar     { $$ = Expr\BinaryOp\SmallerOrEqual[$1, $3]; }
813 |     | static_scalar '>' static_scalar                       { $$ = Expr\BinaryOp\Greater       [$1, $3]; }
814 |     | static_scalar T_IS_GREATER_OR_EQUAL static_scalar     { $$ = Expr\BinaryOp\GreaterOrEqual[$1, $3]; }
815 |     | static_scalar '?' static_scalar ':' static_scalar     { $$ = Expr\Ternary[$1, $3,   $5]; }
816 |     | static_scalar '?' ':' static_scalar                   { $$ = Expr\Ternary[$1, null, $4]; }
817 |     | static_scalar '[' static_scalar ']'                   { $$ = Expr\ArrayDimFetch[$1, $3]; }
818 |     | '(' static_scalar ')'                                 { $$ = $2; }
819 | ;
820 | 
821 | constant:
822 |       name                                                  { $$ = Expr\ConstFetch[$1]; }
823 |     | class_name_or_var T_PAAMAYIM_NEKUDOTAYIM class_const_name
824 |           { $$ = Expr\ClassConstFetch[$1, $3]; }
825 | ;
826 | 
827 | scalar:
828 |       common_scalar                                         { $$ = $1; }
829 |     | constant                                              { $$ = $1; }
830 |     | '"' encaps_list '"'
831 |           { parseEncapsed($2, '"'); $$ = Scalar\Encapsed[$2]; }
832 |     | T_START_HEREDOC encaps_list T_END_HEREDOC
833 |           { parseEncapsedDoc($2); $$ = Scalar\Encapsed[$2]; }
834 | ;
835 | 
836 | class_const_name:
837 |       T_STRING                                              { $$ = $1; }
838 |     | T_CLASS                                               { $$ = 'class'; }
839 | ;
840 | 
841 | static_array_pair_list:
842 |       /* empty */                                           { $$ = array(); }
843 |     | non_empty_static_array_pair_list optional_comma       { $$ = $1; }
844 | ;
845 | 
846 | optional_comma:
847 |       /* empty */
848 |     | ','
849 | ;
850 | 
851 | non_empty_static_array_pair_list:
852 |       non_empty_static_array_pair_list ',' static_array_pair { push($1, $3); }
853 |     | static_array_pair                                      { init($1); }
854 | ;
855 | 
856 | static_array_pair:
857 |       static_scalar T_DOUBLE_ARROW static_scalar            { $$ = Expr\ArrayItem[$3, $1,   false]; }
858 |     | static_scalar                                         { $$ = Expr\ArrayItem[$1, null, false]; }
859 | ;
860 | 
861 | variable:
862 |       object_access                                         { $$ = $1; }
863 |     | base_variable                                         { $$ = $1; }
864 |     | function_call                                         { $$ = $1; }
865 |     | new_expr_array_deref                                  { $$ = $1; }
866 | ;
867 | 
868 | new_expr_array_deref:
869 |       '(' new_expr ')' '[' dim_offset ']'                   { $$ = Expr\ArrayDimFetch[$2, $5]; }
870 |     | new_expr_array_deref '[' dim_offset ']'               { $$ = Expr\ArrayDimFetch[$1, $3]; }
871 |       /* alternative array syntax missing intentionally */
872 | ;
873 | 
874 | object_access:
875 |       variable_or_new_expr T_OBJECT_OPERATOR object_property
876 |           { $$ = Expr\PropertyFetch[$1, $3]; }
877 |     | variable_or_new_expr T_OBJECT_OPERATOR object_property argument_list
878 |           { $$ = Expr\MethodCall[$1, $3, $4]; }
879 |     | object_access argument_list                           { $$ = Expr\FuncCall[$1, $2]; }
880 |     | object_access '[' dim_offset ']'                      { $$ = Expr\ArrayDimFetch[$1, $3]; }
881 |     | object_access '{' expr '}'                            { $$ = Expr\ArrayDimFetch[$1, $3]; }
882 | ;
883 | 
884 | variable_or_new_expr:
885 |       variable                                              { $$ = $1; }
886 |     | '(' new_expr ')'                                      { $$ = $2; }
887 | ;
888 | 
889 | variable_without_objects:
890 |       reference_variable                                    { $$ = $1; }
891 |     | '$' variable_without_objects                          { $$ = Expr\Variable[$2]; }
892 | ;
893 | 
894 | base_variable:
895 |       variable_without_objects                              { $$ = $1; }
896 |     | static_property                                       { $$ = $1; }
897 | ;
898 | 
899 | static_property:
900 |       class_name_or_var T_PAAMAYIM_NEKUDOTAYIM '$' reference_variable
901 |           { $$ = Expr\StaticPropertyFetch[$1, $4]; }
902 |     | static_property_with_arrays                           { $$ = $1; }
903 | ;
904 | 
905 | static_property_with_arrays:
906 |       class_name_or_var T_PAAMAYIM_NEKUDOTAYIM T_VARIABLE
907 |           { $$ = Expr\StaticPropertyFetch[$1, parseVar($3)]; }
908 |     | class_name_or_var T_PAAMAYIM_NEKUDOTAYIM '$' '{' expr '}'
909 |           { $$ = Expr\StaticPropertyFetch[$1, $5]; }
910 |     | static_property_with_arrays '[' dim_offset ']'        { $$ = Expr\ArrayDimFetch[$1, $3]; }
911 |     | static_property_with_arrays '{' expr '}'              { $$ = Expr\ArrayDimFetch[$1, $3]; }
912 | ;
913 | 
914 | reference_variable:
915 |       reference_variable '[' dim_offset ']'                 { $$ = Expr\ArrayDimFetch[$1, $3]; }
916 |     | reference_variable '{' expr '}'                       { $$ = Expr\ArrayDimFetch[$1, $3]; }
917 |     | T_VARIABLE                                            { $$ = Expr\Variable[parseVar($1)]; }
918 |     | '$' '{' expr '}'                                      { $$ = Expr\Variable[$3]; }
919 | ;
920 | 
921 | dim_offset:
922 |       /* empty */                                           { $$ = null; }
923 |     | expr                                                  { $$ = $1; }
924 | ;
925 | 
926 | object_property:
927 |       T_STRING                                              { $$ = $1; }
928 |     | '{' expr '}'                                          { $$ = $2; }
929 |     | variable_without_objects                              { $$ = $1; }
930 | ;
931 | 
932 | list_expr:
933 |       T_LIST '(' list_expr_elements ')'                     { $$ = Expr\List_[$3]; }
934 | ;
935 | 
936 | list_expr_elements:
937 |       list_expr_elements ',' list_expr_element              { push($1, $3); }
938 |     | list_expr_element                                     { init($1); }
939 | ;
940 | 
941 | list_expr_element:
942 |       variable                                              { $$ = $1; }
943 |     | list_expr                                             { $$ = $1; }
944 |     | /* empty */                                           { $$ = null; }
945 | ;
946 | 
947 | array_pair_list:
948 |       /* empty */                                           { $$ = array(); }
949 |     | non_empty_array_pair_list optional_comma              { $$ = $1; }
950 | ;
951 | 
952 | non_empty_array_pair_list:
953 |       non_empty_array_pair_list ',' array_pair              { push($1, $3); }
954 |     | array_pair                                            { init($1); }
955 | ;
956 | 
957 | array_pair:
958 |       expr T_DOUBLE_ARROW expr                              { $$ = Expr\ArrayItem[$3, $1,   false]; }
959 |     | expr                                                  { $$ = Expr\ArrayItem[$1, null, false]; }
960 |     | expr T_DOUBLE_ARROW '&' variable                      { $$ = Expr\ArrayItem[$4, $1,   true]; }
961 |     | '&' variable                                          { $$ = Expr\ArrayItem[$2, null, true]; }
962 | ;
963 | 
964 | encaps_list:
965 |       encaps_list encaps_var                                { push($1, $2); }
966 |     | encaps_list T_ENCAPSED_AND_WHITESPACE                 { push($1, $2); }
967 |     | encaps_var                                            { init($1); }
968 |     | T_ENCAPSED_AND_WHITESPACE encaps_var                  { init($1, $2); }
969 | ;
970 | 
971 | encaps_var:
972 |       T_VARIABLE                                            { $$ = Expr\Variable[parseVar($1)]; }
973 |     | T_VARIABLE '[' encaps_var_offset ']'                  { $$ = Expr\ArrayDimFetch[Expr\Variable[parseVar($1)], $3]; }
974 |     | T_VARIABLE T_OBJECT_OPERATOR T_STRING                 { $$ = Expr\PropertyFetch[Expr\Variable[parseVar($1)], $3]; }
975 |     | T_DOLLAR_OPEN_CURLY_BRACES expr '}'                   { $$ = Expr\Variable[$2]; }
976 |     | T_DOLLAR_OPEN_CURLY_BRACES T_STRING_VARNAME '}'       { $$ = Expr\Variable[$2]; }
977 |     | T_DOLLAR_OPEN_CURLY_BRACES T_STRING_VARNAME '[' expr ']' '}'
978 |           { $$ = Expr\ArrayDimFetch[Expr\Variable[$2], $4]; }
979 |     | T_CURLY_OPEN variable '}'                             { $$ = $2; }
980 | ;
981 | 
982 | encaps_var_offset:
983 |       T_STRING                                              { $$ = Scalar\String_[$1]; }
984 |     | T_NUM_STRING                                          { $$ = Scalar\String_[$1]; }
985 |     | T_VARIABLE                                            { $$ = Expr\Variable[parseVar($1)]; }
986 | ;
987 | 
988 | %%
989 | 


--------------------------------------------------------------------------------
/lib/PhpGenerics/Autoloader.php:
--------------------------------------------------------------------------------
 1 | engine = $engine;
15 |         $this->add(null, $loader->getFallbackDirs());
16 |         $this->addPsr4(null, $loader->getFallbackDirsPsr4());
17 |         foreach ($loader->getPrefixes() as $prefix => $path) {
18 |             $this->add($prefix, $path);
19 |         }
20 |         foreach ($loader->getPrefixesPsr4() as $prefix => $path) {
21 |             $this->addPsr4($prefix, $path);
22 |         }
23 |         $this->setUseIncludePath($loader->getUseIncludePath());
24 |     }
25 | 
26 |     /**
27 |      * Loads the given class or interface.
28 |      *
29 |      * @param  string    $class The name of the class
30 |      * @return bool|null True if loaded, null otherwise
31 |      */
32 |     public function loadClass($class)
33 |     {
34 |         if (strpos($class, Engine::CLASS_TOKEN) !== false) {
35 |             $code = $this->engine->implement($class);
36 |             var_dump($code);
37 |             includeCode($code);
38 | 
39 |             return true;
40 |         }
41 | 
42 |         if ($file = $this->findFile($class)) {
43 |             $code = $this->engine->process($file);
44 |             var_dump($code);
45 |             includeCode($code);
46 |             return true;
47 |         }
48 |     }
49 | }
50 | 
51 | function includeCode($code) {
52 |     eval($code);
53 | }
54 | 


--------------------------------------------------------------------------------
/lib/PhpGenerics/Compiler.php:
--------------------------------------------------------------------------------
  1 | classes[$class])) {
 16 |             return $this->classes[$class];
 17 |         }
 18 |         return null;
 19 |     }
 20 | 
 21 |     public function getClasses() {
 22 |         return $this->classes;
 23 |     }
 24 | 
 25 |     /**
 26 |      * Called once before traversal.
 27 |      *
 28 |      * Return value semantics:
 29 |      *  * null:      $nodes stays as-is
 30 |      *  * otherwise: $nodes is set to the return value
 31 |      *
 32 |      * @param Node[] $nodes Array of nodes
 33 |      *
 34 |      * @return null|Node[] Array of nodes
 35 |      */
 36 |     public function beforeTraverse(array $nodes) {
 37 | 
 38 |     }
 39 | 
 40 |     /**
 41 |      * Called when entering a node.
 42 |      *
 43 |      * Return value semantics:
 44 |      *  * null:      $node stays as-is
 45 |      *  * otherwise: $node is set to the return value
 46 |      *
 47 |      * @param Node $node Node
 48 |      *
 49 |      * @return null|Node Node
 50 |      */
 51 |     public function enterNode(Node $node) {
 52 |         switch ($node->getType()) {
 53 |             case 'Stmt_Class':
 54 |                 $this->classes[(string) $node->namespacedName] = $node;
 55 |                 $this->addGenerics($node);
 56 |                 break;
 57 |             case 'Param':
 58 |                 if ($node->type) {
 59 |                     $type = $node->type instanceof Node\Name ? $node->type->getLast() : $node->type;
 60 |                     if ($node->type instanceof Node\Name && $node->type->hasAttribute("generics") && $node->type->getAttribute("generics")) {
 61 |                         $node->setAttribute("generics", $node->type->getAttribute("generics"));
 62 |                         $node->setAttribute("original_type", $node->type);
 63 |                     }
 64 |                     if (isset($this->currentGenerics[$type])) {
 65 |                         $node->type = null;
 66 |                         $node->setAttribute("generic_name", $type);
 67 |                     } 
 68 | 
 69 |                 }
 70 |                 break;
 71 |             case 'Expr_New':
 72 |                 // replace generics
 73 |                 if (!$node->getAttribute("generics")) {
 74 |                     break;
 75 |                 }
 76 |                 if ($node->class instanceof Node\Name) {
 77 |                     foreach ($node->getAttribute("generics") as $generic) {
 78 |                         $generic = str_replace("\\", Engine::NS_TOKEN, $generic);
 79 |                         $node->class->append(Engine::CLASS_TOKEN . $generic . Engine::CLASS_TOKEN);
 80 |                     }
 81 |                 } else {
 82 |                     // dirty hack!
 83 |                     $node->class = $this->appendDynamicVariable($node->class, $node->getAttribute("generics"));
 84 |                 }
 85 |                 break;
 86 |             case 'Name_FullyQualified':
 87 |                 break;
 88 |             default:
 89 |                 if ($node->hasAttribute("generics") && $node->getAttribute("generics")) {
 90 |                     throw new \RuntimeException("Not implemented yet " . $node->getType());
 91 |                 }
 92 |         }
 93 |         if (isset($node->returnType) && version_compare(PHP_VERSION, "7.0", "<")) {
 94 |             unset($node->returnType);
 95 |         }
 96 |     }
 97 | 
 98 |     /**
 99 |      * Called when leaving a node.
100 |      *
101 |      * Return value semantics:
102 |      *  * null:      $node stays as-is
103 |      *  * false:     $node is removed from the parent array
104 |      *  * array:     The return value is merged into the parent array (at the position of the $node)
105 |      *  * otherwise: $node is set to the return value
106 |      *
107 |      * @param Node $node Node
108 |      *
109 |      * @return null|Node|false|Node[] Node
110 |      */
111 |     public function leaveNode(Node $node) {
112 |         switch ($node->getType()) {
113 |             case 'Stmt_Class':
114 |                 $this->removeGenerics($node);
115 |                 break;
116 |         }
117 |     }
118 | 
119 |     /**
120 |      * Called once after traversal.
121 |      *
122 |      * Return value semantics:
123 |      *  * null:      $nodes stays as-is
124 |      *  * otherwise: $nodes is set to the return value
125 |      *
126 |      * @param Node[] $nodes Array of nodes
127 |      *
128 |      * @return null|Node[] Array of nodes
129 |      */
130 |     public function afterTraverse(array $nodes) {
131 | 
132 |     }
133 | 
134 |     protected function appendDynamicVariable($existing, array $generics) {
135 |         throw new \Exception("Not implemented");
136 |     }
137 | 
138 |     protected function addGenerics(Node $node) {
139 |         if (!$node->hasAttribute('generics') || !$node->getAttribute('generics')) {
140 |             return;
141 |         }
142 |         foreach ($node->getAttribute('generics') as $type) {
143 |             $this->currentGenerics[$type] = $type;
144 |         }
145 |     }
146 | 
147 |     protected function removeGenerics(Node $node) {
148 |         if (!$node->hasAttribute('generics') || !$node->getAttribute('generics')) {
149 |             return;
150 |         }
151 |         foreach ($node->getAttribute('generics') as $type) {
152 |             unset($this->currentGenerics[$type]);
153 |         }
154 |     }
155 | 
156 | }
157 | 


--------------------------------------------------------------------------------
/lib/PhpGenerics/Engine.php:
--------------------------------------------------------------------------------
 1 | parser = $parser;
25 |         if (!$compiler) {
26 |             $compiler = new Compiler;
27 |         }
28 |         $this->compiler = $compiler;
29 |         $this->prettyPrinter = new Standard;
30 |         $this->traverser = new NodeTraverser;
31 |         $this->traverser->addVisitor(new NameResolver);
32 |         $this->traverser->addVisitor($this->compiler);
33 |     }
34 | 
35 |     public function process($file) {
36 |         $code = file_get_contents($file);
37 |         $ast = $this->parser->parse($code);
38 |         $processed = $this->traverser->traverse($ast);
39 |         return $this->prettyPrinter->prettyPrint($processed);
40 |     }
41 | 
42 |     public function implement($class) {
43 |         $parts = $orig_parts = explode("\\", ltrim($class, "\\"));
44 |         $real_class_parts = [];
45 |         while ($part = array_shift($parts)) {
46 |             if (strpos($part, self::CLASS_TOKEN) !== false) {
47 |                 break;
48 |             }
49 |             $real_class_parts[] = $part;
50 |         }
51 |         array_unshift($parts, $part);
52 | 
53 |         $types = [];
54 |         foreach ($parts as $part) {
55 |             $types[] = str_replace([self::CLASS_TOKEN, self::NS_TOKEN], ["", "\\"], $part);
56 |         }
57 | 
58 |         $real_class = implode("\\", $real_class_parts);
59 |         if (!class_exists($real_class)) {
60 |             throw new \RuntimeException("Attempting to use generics on unknown class $real_class");
61 |         }
62 |         if (!($ast = $this->compiler->getClass($real_class))) {
63 |             throw new \RuntimeException("Attempting to use generics with non-generic class");
64 |         }
65 | 
66 | 
67 | 
68 |         $generator = new Generator($ast->getAttribute("generics"), $types);
69 |         $traverser = new NodeTraverser;
70 |         $traverser->addVisitor($generator);
71 |         $ast = $traverser->traverse([$ast]);
72 |         $ast[0]->name = array_pop($orig_parts);
73 |         $ast[0]->extends = new Node\Name\FullyQualified($real_class_parts);
74 |         array_unshift($ast, new Node\Stmt\Namespace_(new Node\Name($orig_parts)));
75 |         return $this->prettyPrinter->prettyPrint($ast);
76 |     }
77 | }
78 | 


--------------------------------------------------------------------------------
/lib/PhpGenerics/Generator.php:
--------------------------------------------------------------------------------
  1 | genericTypes = array_combine($names, $types);
 17 |     }
 18 | 
 19 |     /**
 20 |      * Called once before traversal.
 21 |      *
 22 |      * Return value semantics:
 23 |      *  * null:      $nodes stays as-is
 24 |      *  * otherwise: $nodes is set to the return value
 25 |      *
 26 |      * @param Node[] $nodes Array of nodes
 27 |      *
 28 |      * @return null|Node[] Array of nodes
 29 |      */
 30 |     public function beforeTraverse(array $nodes) {
 31 | 
 32 |     }
 33 | 
 34 |     /**
 35 |      * Called when entering a node.
 36 |      *
 37 |      * Return value semantics:
 38 |      *  * null:      $node stays as-is
 39 |      *  * otherwise: $node is set to the return value
 40 |      *
 41 |      * @param Node $node Node
 42 |      *
 43 |      * @return null|Node Node
 44 |      */
 45 |     public function enterNode(Node $node) {
 46 |         if (isset($node->returnType)) {
 47 |             var_dump($node->returnType);
 48 |             die();
 49 |         } elseif ($node instanceof Node\Param) {
 50 |             if ($node->hasAttribute("generic_name")) {
 51 |                 $type = $node->getAttribute("generic_name");
 52 |                 if (isset($this->genericTypes[$type])) {
 53 |                     $node->type = new Node\Name\FullyQualified($this->genericTypes[$type]);
 54 |                 } else {
 55 |                     throw new \LogicException("Bad generic found");
 56 |                 }
 57 |             } elseif ($node->type instanceof Node\Name && $node->type->hasAttribute("generics") && $node->type->getAttribute("generics")) {
 58 |                 $type = $node->getAttribute("original_type")->parts;
 59 |                 foreach ($node->type->getAttribute("generics") as $generic) {
 60 |                     if (isset($this->genericTypes[$generic])) {
 61 |                         $value =  str_replace("\\", Engine::NS_TOKEN, $this->genericTypes[$generic]);
 62 |                         $type[] = Engine::CLASS_TOKEN . $value . Engine::CLASS_TOKEN;
 63 |                     } else {
 64 |                         throw new \LogicException("Bad generic found");
 65 |                     }
 66 |                 }
 67 |                 $node->type = new Node\Name\FullyQualified($type);
 68 |             } elseif (((string) $node->name) == "item") {
 69 |                 var_dump($node);
 70 |                 die();
 71 |             }
 72 |         }
 73 |     }
 74 | 
 75 |     /**
 76 |      * Called when leaving a node.
 77 |      *
 78 |      * Return value semantics:
 79 |      *  * null:      $node stays as-is
 80 |      *  * false:     $node is removed from the parent array
 81 |      *  * array:     The return value is merged into the parent array (at the position of the $node)
 82 |      *  * otherwise: $node is set to the return value
 83 |      *
 84 |      * @param Node $node Node
 85 |      *
 86 |      * @return null|Node|false|Node[] Node
 87 |      */
 88 |     public function leaveNode(Node $node) {
 89 | 
 90 |     }
 91 | 
 92 |     /**
 93 |      * Called once after traversal.
 94 |      *
 95 |      * Return value semantics:
 96 |      *  * null:      $nodes stays as-is
 97 |      *  * otherwise: $nodes is set to the return value
 98 |      *
 99 |      * @param Node[] $nodes Array of nodes
100 |      *
101 |      * @return null|Node[] Array of nodes
102 |      */
103 |     public function afterTraverse(array $nodes) {
104 | 
105 |     }
106 | 
107 | }
108 | 


--------------------------------------------------------------------------------
/lib/PhpGenerics/Parser.php:
--------------------------------------------------------------------------------
   1 | '",
 206 |         "T_IS_GREATER_OR_EQUAL",
 207 |         "T_SL",
 208 |         "T_SR",
 209 |         "'+'",
 210 |         "'-'",
 211 |         "'.'",
 212 |         "'*'",
 213 |         "'/'",
 214 |         "'%'",
 215 |         "'!'",
 216 |         "T_INSTANCEOF",
 217 |         "'~'",
 218 |         "T_INC",
 219 |         "T_DEC",
 220 |         "T_INT_CAST",
 221 |         "T_DOUBLE_CAST",
 222 |         "T_STRING_CAST",
 223 |         "T_ARRAY_CAST",
 224 |         "T_OBJECT_CAST",
 225 |         "T_BOOL_CAST",
 226 |         "T_UNSET_CAST",
 227 |         "'@'",
 228 |         "T_POW",
 229 |         "'['",
 230 |         "T_NEW",
 231 |         "T_CLONE",
 232 |         "T_EXIT",
 233 |         "T_IF",
 234 |         "T_ELSEIF",
 235 |         "T_ELSE",
 236 |         "T_ENDIF",
 237 |         "T_LNUMBER",
 238 |         "T_DNUMBER",
 239 |         "T_STRING",
 240 |         "T_STRING_VARNAME",
 241 |         "T_VARIABLE",
 242 |         "T_NUM_STRING",
 243 |         "T_INLINE_HTML",
 244 |         "T_ENCAPSED_AND_WHITESPACE",
 245 |         "T_CONSTANT_ENCAPSED_STRING",
 246 |         "T_ECHO",
 247 |         "T_DO",
 248 |         "T_WHILE",
 249 |         "T_ENDWHILE",
 250 |         "T_FOR",
 251 |         "T_ENDFOR",
 252 |         "T_FOREACH",
 253 |         "T_ENDFOREACH",
 254 |         "T_DECLARE",
 255 |         "T_ENDDECLARE",
 256 |         "T_AS",
 257 |         "T_SWITCH",
 258 |         "T_ENDSWITCH",
 259 |         "T_CASE",
 260 |         "T_DEFAULT",
 261 |         "T_BREAK",
 262 |         "T_CONTINUE",
 263 |         "T_GOTO",
 264 |         "T_FUNCTION",
 265 |         "T_CONST",
 266 |         "T_RETURN",
 267 |         "T_TRY",
 268 |         "T_CATCH",
 269 |         "T_FINALLY",
 270 |         "T_THROW",
 271 |         "T_USE",
 272 |         "T_INSTEADOF",
 273 |         "T_GLOBAL",
 274 |         "T_STATIC",
 275 |         "T_ABSTRACT",
 276 |         "T_FINAL",
 277 |         "T_PRIVATE",
 278 |         "T_PROTECTED",
 279 |         "T_PUBLIC",
 280 |         "T_VAR",
 281 |         "T_UNSET",
 282 |         "T_ISSET",
 283 |         "T_EMPTY",
 284 |         "T_HALT_COMPILER",
 285 |         "T_CLASS",
 286 |         "T_TRAIT",
 287 |         "T_INTERFACE",
 288 |         "T_EXTENDS",
 289 |         "T_IMPLEMENTS",
 290 |         "T_OBJECT_OPERATOR",
 291 |         "T_DOUBLE_ARROW",
 292 |         "T_LIST",
 293 |         "T_ARRAY",
 294 |         "T_CALLABLE",
 295 |         "T_CLASS_C",
 296 |         "T_TRAIT_C",
 297 |         "T_METHOD_C",
 298 |         "T_FUNC_C",
 299 |         "T_LINE",
 300 |         "T_FILE",
 301 |         "T_START_HEREDOC",
 302 |         "T_END_HEREDOC",
 303 |         "T_DOLLAR_OPEN_CURLY_BRACES",
 304 |         "T_CURLY_OPEN",
 305 |         "T_PAAMAYIM_NEKUDOTAYIM",
 306 |         "T_NAMESPACE",
 307 |         "T_NS_C",
 308 |         "T_DIR",
 309 |         "T_NS_SEPARATOR",
 310 |         "T_ELLIPSIS",
 311 |         "';'",
 312 |         "'{'",
 313 |         "'}'",
 314 |         "'('",
 315 |         "')'",
 316 |         "'$'",
 317 |         "'`'",
 318 |         "']'",
 319 |         "'\"'"
 320 |     );
 321 | 
 322 |     protected $tokenToSymbol = array(
 323 |             0,  156,  156,  156,  156,  156,  156,  156,  156,  156,
 324 |           156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
 325 |           156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
 326 |           156,  156,  156,   51,  155,  156,  152,   50,   33,  156,
 327 |           150,  151,   48,   45,    7,   46,   47,   49,  156,  156,
 328 |           156,  156,  156,  156,  156,  156,  156,  156,   27,  147,
 329 |            39,   13,   41,   26,   63,  156,  156,  156,  156,  156,
 330 |           156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
 331 |           156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
 332 |           156,   65,  156,  154,   32,  156,  153,  156,  156,  156,
 333 |           156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
 334 |           156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
 335 |           156,  156,  156,  148,   31,  149,   53,  156,  156,  156,
 336 |           156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
 337 |           156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
 338 |           156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
 339 |           156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
 340 |           156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
 341 |           156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
 342 |           156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
 343 |           156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
 344 |           156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
 345 |           156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
 346 |           156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
 347 |           156,  156,  156,  156,  156,  156,  156,  156,  156,  156,
 348 |           156,  156,  156,  156,  156,  156,    1,    2,    3,    4,
 349 |             5,    6,    8,    9,   10,   11,   12,   14,   15,   16,
 350 |            17,   18,   19,   20,   21,   22,   23,   24,   25,   28,
 351 |            29,   30,   34,   35,   36,   37,   38,   40,   42,   43,
 352 |            44,   52,   54,   55,   56,   57,   58,   59,   60,   61,
 353 |            62,   64,   66,   67,   68,   69,   70,   71,   72,   73,
 354 |            74,   75,   76,   77,   78,   79,  156,  156,   80,   81,
 355 |            82,   83,   84,   85,   86,   87,   88,   89,   90,   91,
 356 |            92,   93,   94,   95,   96,   97,   98,   99,  100,  101,
 357 |           102,  103,  104,  105,  106,  107,  108,  109,  110,  111,
 358 |           112,  113,  114,  115,  116,  117,  118,  119,  120,  121,
 359 |           122,  123,  124,  125,  126,  127,  128,  129,  130,  131,
 360 |           132,  133,  134,  135,  136,  156,  156,  156,  156,  156,
 361 |           156,  137,  138,  139,  140,  141,  142,  143,  144,  145,
 362 |           146
 363 |     );
 364 | 
 365 |     protected $action = array(
 366 |            60,   61,  420,   62,   63,-32766,-32766,-32766,-32766,   64,
 367 |            65,  221,  222,  223,  224,  225,  226,  227,  228,  229,
 368 |           655,  230,  231,  232,  233,  234,  235,  236,  237,  238,
 369 |           239,  240,  241,-32766,-32766,-32766,-32766,-32766,-32767,-32767,
 370 |         -32767,-32767,   31,   66,   67,  614,  242,  243,    0,   68,
 371 |           365,   69,  294,  295,   70,   71,   72,   73,   74,   75,
 372 |            76,   77,   35,   32,  304,   78,  412,  421,  134,  128,
 373 |           417,  974,  975,  469,  366, 1067,  334,  701,  345,  470,
 374 |            46,   27,  422,  760,  471,  827,  472,  497,  473,  443,
 375 |           425,  423,  218,  219,  220,   36,   37,  474,  428,  285,
 376 |            38,  475,  424,  413,   79,  419,  301,  357,  358,  323,
 377 |           205,  209,  465,  476,  477,  478,  479,  480,  726,  814,
 378 |          1033,  378,  661,  732,  481,  482,  483,  484,  926,  980,
 379 |           981,  982,  983,  977,  978,  312,   83,   84,   85,  542,
 380 |           497,  984,  979,  425,  336,  707,  624,  131,   47,  298,
 381 |           337,  324, 1096,  328,   40,  283,   86,   87,   88,   89,
 382 |            90,   91,   92,   93,   94,   95,   96,   97,   98,   99,
 383 |           100,  101,  102,  103,  104,  105,  106,  107,  108, -123,
 384 |           305,  298,  310,   39,  297,-32766,  791,-32766,-32766,-32766,
 385 |           698,  655,  109, 1032, 1099,-32766, 1101, 1100,-32766,-32766,
 386 |         -32766,  483,-32766,  761,-32766,-32766,-32766,-32766,-32766,-32766,
 387 |           218,  219,  220,-32766,-32766,-32766,  448,-32766,-32766,-32766,
 388 |           784,  785,-32766,  655,-32766,-32766,  496,-32766,  205,  699,
 389 |         -32766,-32766,-32766,-32766,-32766, 1025,-32766,   58,-32766, 1033,
 390 |           926,-32766, -127, 1074,  439,-32766,-32766,-32766,  578,  941,
 391 |         -32766,-32766,  809,  339,-32766,  354,  355,-32766,  496,-32766,
 392 |         -32766,-32766,  132,-32766,-32766,-32766,  835,  836,  837,  834,
 393 |           833,  832,  926,  218,  219,  220,  800,-32766,  356,-32766,
 394 |         -32766,-32766,-32766,-32766,-32766,-32767,-32767,-32767,-32767,-32767,
 395 |           442,  205, 1061,  286,  132,-32766,-32766,-32766,  326,  790,
 396 |           415,   54,  300,  655,  388,   55,  986,-32766,-32766,-32766,
 397 |         -32766,-32766,-32766,  417,-32766,  926,-32766,  220,-32766,  334,
 398 |           127,-32766,  218,  219,  220,-32766,-32766,-32766,  827,-32766,
 399 |         -32766,-32766,   57,  205,-32766,  655,  296,-32766,  496,-32766,
 400 |           205,  246,-32766,-32766,-32766,-32766,-32766,  926,-32766,  417,
 401 |         -32766,  287, 1067,-32766,  623,  334, 1024,-32766,-32766,-32766,
 402 |            22,  725,-32766,-32766,  827,  440,-32766,  346,  299,-32766,
 403 |           496,  122,-32766,  219,  220,-32766,-32766,-32766,  655,  106,
 404 |           107,  108,-32766,  305,  123,-32766,-32766,-32766,  124,-32766,
 405 |           205,-32766,  244,-32766, -301,  109,-32766,  724,-32766,-32766,
 406 |         -32766,-32766,-32766,  -76,-32766,-32766,-32766,-32766,-32766,-32766,
 407 |           655,  205,-32766,  496,-32766,  125,  447,-32766,-32766,-32766,
 408 |         -32766,-32766, 1089,-32766,  926,-32766,  819,  337,-32766,-32766,
 409 |         -32766,-32766,-32766,-32766,-32766, 1071,  136,-32766,-32766,  130,
 410 |           570,-32766,  210,  329,-32766,  496,  239,  240,  241,  211,
 411 |         -32766,-32766,-32766,-32766,-32766,-32766,  926,-32766,-32766,-32766,
 412 |         -32766,-32766,  242,  243,  212,   41,  110,  111,  112,  113,
 413 |           114,  115,  116,  117,  118,  119,  120,  121,  103,  104,
 414 |           105,-32766,-32766,-32766,  236,  237,  238,  655,  247,  131,
 415 |          1089,-32766,  453,   28,-32766,-32766,-32766, 1030,-32766,  926,
 416 |         -32766,  986,-32766,  248,  569,-32766,  865,  867,  133,-32766,
 417 |         -32766,-32766,  311,-32766,-32766,-32766,  639,  728,-32766,  655,
 418 |           643,-32766,  496,-32766,  242,  243,-32766,-32766,-32766,-32766,
 419 |         -32766,  926,-32766,  435,-32766,  711,  626,-32766,  729,  458,
 420 |           584,-32766,-32766,-32766,  137,  367,-32766,-32766, 1031,  135,
 421 |         -32766,  730,  627,-32766,  496,  629,-32766,  592,  593,-32766,
 422 |         -32766,-32766,  655,-32766,-32766,-32766,-32766,  784,  785,-32766,
 423 |         -32766,-32766,  635,-32766,  926,-32766,  640,-32766, -402,  646,
 424 |         -32766,-32766,  662,  630,-32766,-32766,-32766,-32766,-32766,-32766,
 425 |         -32766,-32766,-32766,-32766,  655,  364,-32766,  496,-32766,  720,
 426 |           305,-32766,-32766,-32766,-32766,-32766,  109,-32766,   49,-32766,
 427 |           824,  650,-32766,  813,  645,   50,-32766,-32766,-32766,   51,
 428 |           343,-32766,-32766,  304,   52,-32766,   53,  344,-32766,  496,
 429 |            56,-32766,   59, 1089,  691,-32766,-32766,  655,  218,  219,
 430 |           220,-32766,  598,  433,-32766,-32766,-32766,  434,-32766,  437,
 431 |         -32766,  245,-32766,  441,  466,-32766,  205,  517,  518,-32766,
 432 |         -32766,-32766,  533,  621,-32766,-32766,  693,-32766,-32766,  213,
 433 |           214,-32766,  496,  655,  656,  215,  672,  216, 1094,-32766,
 434 |         -32766,-32766,-32766,-32766,-32766,-32766,-32766,-32766,-32766,  207,
 435 |         -32767,-32767,-32767,-32767,  674,  731,  821,  974,  975, -175,
 436 |           521,-32766,-32766,  604,  605,  976,  612, -172,  655,  695,
 437 |         -32766,  944,-32766,  432,  464,-32766,-32766,-32766,  589,-32766,
 438 |           438,-32766,  576,-32766,  303,  587,-32766,  535,  733,  564,
 439 |         -32766,-32766,-32766,  282,  332,-32766,-32766,  734, -402,-32766,
 440 |           985,  338,-32766,  496,  325, -309,  335, -301,   82,  315,
 441 |         -32766,  327,   44,  561,  435,  980,  981,  982,  983,  977,
 442 |           978,  395,    0,  213,  214,  333,   42,  984,  979,  215,
 443 |          -403,  216,  126,    0,  217,  483,-32766,    0,    0,    0,
 444 |         -32766,-32766,    0,  207,  967,    0,    0,  331,-32766,  368,
 445 |           381,  974,  975,  620,  655,-32766, -310,   45,-32766,  976,
 446 |           722,-32766,-32766,-32766,  526,-32766,  415,-32766,  625,-32766,
 447 |           631,  632,-32766,  697,  710,  688,-32766,-32766,-32766,  703,
 448 |           763,-32766,-32766,  424,  413,-32766,  754,  755,-32766,  496,
 449 |           323,  686,  748,  746,  476,  477,-32766,  744,-32766,-32766,
 450 |         -32766,  820,  818,  661,  732,  481,  482,  561,  702,  980,
 451 |           981,  982,  983,  977,  978,  395,-32766,  692,-32766,-32766,
 452 |         -32766,  984,  979,  694,  696,  336,-32766,-32766,  217,  709,
 453 |         -32766,  700,  664,  424,  413,  817,  665,  666,  667,  668,
 454 |           323,-32766,-32766,-32766,  476,  477,  810, 1098,  634,-32766,
 455 |         -32766,-32766,  636,  661,  732,  481,  482,  638,  642,-32766,
 456 |           644,-32766,-32766,-32766,-32766,-32766,-32766,-32766,  647,-32766,
 457 |         -32766,-32766,-32766,-32766,  648,  336,  649,  129, -124, 1097,
 458 |           752,  424,  663,-32767,-32767,-32767,-32767,  101,  102,  103,
 459 |           104,  105,  476,  477,  424,  753,  457, 1095,  424, 1068,
 460 |          1066,  683,  732,  481,  482,  476,  477, 1052, 1064,  476,
 461 |           477,  424,  965,  802,  683,  732,  481,  482,  683,  732,
 462 |           481,  482,  476,  477, 1072, 1062,  924,   30,  424,   33,
 463 |           633,  683,  732,  481,  482,   34,   43,   48,   80,  476,
 464 |           477,   81,  424,  684, -123,  208,  424,  716,  683,  732,
 465 |           481,  482,  284,  476,  477,  292,  293,  476,  477,  424,
 466 |           927,  573,  683,  732,  481,  482,  683,  732,  481,  482,
 467 |           476,  477,  306,  307,  308,  309,  424,  723,   23,  683,
 468 |           732,  481,  482,   24,  340,  411,  414,  476,  477,  619,
 469 |         -32766,  928,  934,  -76,    0,  714,  683,  732,  481,  482,
 470 |           602,   25,  424,  389,  611,  454,  460,  462,  825,  424,
 471 |           655,  467, 1067,  476,  477,  424,  555,  613,  930,  933,
 472 |           476,  477,  683,  732,  481,  482,  476,  477,  792,  683,
 473 |           732,  481,  482,  990,  929,  683,  732,  481,  482,-32766,
 474 |         -32766,-32766,  906,  424,  565,  951,  905,    0,  936,    0,
 475 |           935,  938,  937,  950,  476,  477,    0,-32766, 1065,-32766,
 476 |         -32766,-32766,-32766,  683,  732,  481,  482, 1051, 1047,    0,
 477 |          1063,  964, 1093,  991, 1046,  595,    0,  497,    0,    0,
 478 |           425,    0,    0,    0,    0,  429,    0,  337
 479 |     );
 480 | 
 481 |     protected $actionCheck = array(
 482 |             2,    3,    4,    5,    6,   29,   30,   31,   32,   11,
 483 |            12,   29,   30,   31,   32,   33,   34,   35,   36,   37,
 484 |            75,   39,   40,   41,   42,   43,   44,   45,   46,   47,
 485 |            48,   49,   50,   29,   30,   31,   32,   33,   34,   35,
 486 |            36,   37,    7,   45,   46,   75,   64,   65,    0,   51,
 487 |             7,   53,   54,   55,   56,   57,   58,   59,   60,   61,
 488 |            62,   63,    7,   65,   66,   67,   68,   69,   65,    7,
 489 |           101,   73,   74,   75,   75,   77,  107,   79,   65,   81,
 490 |            82,   83,   84,   27,   86,  116,   88,  142,   90,    7,
 491 |           145,   93,    8,    9,   10,   97,   98,   99,  100,    7,
 492 |           102,  103,  100,  101,  106,    7,   33,  109,  110,  107,
 493 |            26,    7,    7,  111,  112,  117,  118,  119,  149,  149,
 494 |           121,   77,  120,  121,  122,  123,  128,  129,   12,  131,
 495 |           132,  133,  134,  135,  136,  137,    8,    9,   10,  126,
 496 |           142,  143,  144,  145,  142,  147,  148,  148,  150,   33,
 497 |           152,  153,  149,  155,   26,  127,   28,   29,   30,   31,
 498 |            32,   33,   34,   35,   36,   37,   38,   39,   40,   41,
 499 |            42,   43,   44,   45,   46,   47,   48,   49,   50,  151,
 500 |            52,   33,    7,  139,  140,   69,  151,    8,    9,   10,
 501 |           147,   75,   64,   75,   75,   79,   77,   78,   82,   83,
 502 |            84,  128,   86,  147,   88,   26,   90,   28,   29,   93,
 503 |             8,    9,   10,   97,   98,   99,    7,   69,  102,  103,
 504 |           129,  130,  106,   75,    8,  109,  110,   79,   26,  147,
 505 |            82,   83,   84,  117,   86,  151,   88,   65,   90,  121,
 506 |            12,   93,  151,  151,   27,   97,   98,   99,   80,  151,
 507 |           102,  103,  147,    7,  106,  100,  101,  109,  110,    8,
 508 |             9,   10,  146,  147,  148,  117,  110,  111,  112,  113,
 509 |           114,  115,   12,    8,    9,   10,   77,   26,    7,   28,
 510 |            29,   30,   31,   32,   33,   34,   35,   36,   37,   38,
 511 |             7,   26,   77,   33,  146,  147,  148,   69,  126,  151,
 512 |           145,   65,    7,   75,   76,   65,  138,   79,    8,    9,
 513 |            82,   83,   84,  101,   86,   12,   88,   10,   90,  107,
 514 |           148,   93,    8,    9,   10,   97,   98,   99,  116,   69,
 515 |           102,  103,   65,   26,  106,   75,   33,  109,  110,   79,
 516 |            26,   27,   82,   83,   84,  117,   86,   12,   88,  101,
 517 |            90,  152,   77,   93,   75,  107,  154,   97,   98,   99,
 518 |           151,  149,  102,  103,  116,  148,  106,  152,   33,  109,
 519 |           110,   13,   69,    9,   10,  147,  148,  117,   75,   48,
 520 |            49,   50,   79,   52,  148,   82,   83,   84,  148,   86,
 521 |            26,   88,  127,   90,  141,   64,   93,  149,   29,   30,
 522 |            97,   98,   99,  150,   69,  102,  103,  147,  148,  106,
 523 |            75,   26,  109,  110,   79,  148,   75,   82,   83,   84,
 524 |           117,   86,   80,   88,   12,   90,  147,  152,   93,    8,
 525 |             9,   10,   97,   98,   99,   75,  148,  102,  103,   27,
 526 |           152,  106,   13,   80,  109,  110,   48,   49,   50,   13,
 527 |           147,  148,  117,   29,   30,   31,   12,   29,   30,   31,
 528 |            32,   33,   64,   65,   13,   13,   14,   15,   16,   17,
 529 |            18,   19,   20,   21,   22,   23,   24,   25,   45,   46,
 530 |            47,   69,  147,  148,   45,   46,   47,   75,   13,  148,
 531 |            80,   79,   70,   71,   82,   83,   84,  155,   86,   12,
 532 |            88,  138,   90,   13,    7,   93,   54,   55,  148,   97,
 533 |            98,   99,   27,   69,  102,  103,   27,   41,  106,   75,
 534 |            27,  109,  110,   79,   64,   65,   82,   83,   84,  117,
 535 |            86,   12,   88,  145,   90,   27,  148,   93,   41,   70,
 536 |            71,   97,   98,   99,   95,   96,  102,  103,  138,   27,
 537 |           106,   75,   27,  109,  110,   27,   69,  104,  105,  147,
 538 |           148,  117,   75,    8,    9,   10,   79,  129,  130,   82,
 539 |            83,   84,   27,   86,   12,   88,   27,   90,  126,   27,
 540 |            93,   26,  147,  148,   97,   98,   99,   29,   69,  102,
 541 |           103,  147,  148,  106,   75,   39,  109,  110,   79,   33,
 542 |            52,   82,   83,   84,  117,   86,   64,   88,   65,   90,
 543 |           147,  148,   93,  147,  148,   65,   97,   98,   99,   65,
 544 |            80,  102,  103,   66,   65,  106,   65,   80,  109,  110,
 545 |            65,   69,   65,   80,  147,  148,  117,   75,    8,    9,
 546 |            10,   79,   72,   75,   82,   83,   84,   75,   86,   75,
 547 |            88,   27,   90,   75,   75,   93,   26,   75,   75,   97,
 548 |            98,   99,   75,   75,  102,  103,  147,  148,  106,   45,
 549 |            46,  109,  110,   75,   75,   51,   75,   53,   75,  117,
 550 |            29,   30,   31,   32,   33,   34,   35,   36,   37,   65,
 551 |            39,   40,   41,   42,   75,   75,   75,   73,   74,   77,
 552 |            77,   77,   69,   77,   77,   81,   77,   92,   75,  147,
 553 |           148,   77,   79,  100,  100,   82,   83,   84,  107,   86,
 554 |            84,   88,   94,   90,   92,   94,   93,   92,  121,   92,
 555 |            97,   98,   99,   92,  124,  102,  103,  121,  126,  106,
 556 |           138,  124,  109,  110,  126,  141,  108,  141,  148,  141,
 557 |           117,  126,  147,  129,  145,  131,  132,  133,  134,  135,
 558 |           136,  137,   -1,   45,   46,  125,  127,  143,  144,   51,
 559 |           126,   53,  127,   -1,  150,  128,  152,   -1,   -1,   -1,
 560 |           147,  148,   -1,   65,  151,   -1,   -1,  141,   69,  141,
 561 |           141,   73,   74,  141,   75,   77,  141,  147,   79,   81,
 562 |           146,   82,   83,   84,  145,   86,  145,   88,  148,   90,
 563 |           147,  147,   93,  147,  147,  147,   97,   98,   99,  147,
 564 |           147,  102,  103,  100,  101,  106,  147,  147,  109,  110,
 565 |           107,  147,  147,  147,  111,  112,  117,  147,    8,    9,
 566 |            10,  147,  147,  120,  121,  122,  123,  129,  147,  131,
 567 |           132,  133,  134,  135,  136,  137,   26,  147,   28,   29,
 568 |            30,  143,  144,  147,  147,  142,  147,  148,  150,  147,
 569 |           152,  147,  149,  100,  101,  147,  147,  147,  147,  147,
 570 |           107,    8,    9,   10,  111,  112,  147,  149,  148,    8,
 571 |             9,   10,  148,  120,  121,  122,  123,  148,  148,   26,
 572 |           148,   28,   29,   30,   31,   32,   33,   26,  148,   28,
 573 |            29,   30,   31,   32,  148,  142,  148,  148,  151,  149,
 574 |           149,  100,  149,   39,   40,   41,   42,   43,   44,   45,
 575 |            46,   47,  111,  112,  100,  149,  149,  149,  100,  149,
 576 |           149,  120,  121,  122,  123,  111,  112,  149,  149,  111,
 577 |           112,  100,  149,  149,  120,  121,  122,  123,  120,  121,
 578 |           122,  123,  111,  112,  149,  149,  153,  150,  100,  150,
 579 |           149,  120,  121,  122,  123,  150,  150,  150,  150,  111,
 580 |           112,  150,  100,  149,  151,  150,  100,  149,  120,  121,
 581 |           122,  123,  150,  111,  112,  150,  150,  111,  112,  100,
 582 |           149,   85,  120,  121,  122,  123,  120,  121,  122,  123,
 583 |           111,  112,  150,  150,  150,  150,  100,  149,  151,  120,
 584 |           121,  122,  123,  151,  150,  150,  150,  111,  112,   87,
 585 |           150,  149,  154,  150,   -1,  149,  120,  121,  122,  123,
 586 |            91,  151,  100,  151,   89,  151,  151,  151,  149,  100,
 587 |            75,  151,   77,  111,  112,  100,  151,  151,  151,  151,
 588 |           111,  112,  120,  121,  122,  123,  111,  112,  151,  120,
 589 |           121,  122,  123,  151,  151,  120,  121,  122,  123,    8,
 590 |             9,   10,  151,  100,  151,  110,  151,   -1,  154,   -1,
 591 |           154,  154,  154,  154,  111,  112,   -1,   26,  154,   28,
 592 |            29,   30,   31,  120,  121,  122,  123,  154,  154,   -1,
 593 |           154,  154,  154,  154,  154,  154,   -1,  142,   -1,   -1,
 594 |           145,   -1,   -1,   -1,   -1,  150,   -1,  152
 595 |     );
 596 | 
 597 |     protected $actionBase = array(
 598 |             0,  723,  773,    2,  834,  821,  916,  949,  955,  838,
 599 |           851,  942,  868,  882,  886,  899,  983,  983,  983,  983,
 600 |           983,  528,  545,  549,  552,  549,  525,   -2,   -2,   -2,
 601 |           148,  116,  303,  303,  633,  303,  487,  519,  562,  228,
 602 |           412,  260,  335,  444,  444,  444,  444,  719,  719,  444,
 603 |           444,  444,  444,  444,  444,  444,  444,  444,  444,  444,
 604 |           444,  444,  444,  444,  444,  444,  444,  444,  444,  444,
 605 |           444,  444,  444,  444,  444,  444,  444,  444,  444,  444,
 606 |           444,  444,  444,  444,  444,  444,  444,  444,  444,  444,
 607 |           444,  444,  444,  444,  444,  444,  444,  444,  444,  444,
 608 |           444,  444,  444,  444,  444,  444,  444,  444,  444,  444,
 609 |           444,  444,  444,  444,  444,  444,  444,  444,  444,  444,
 610 |           444,  444,  444,  444,  444,  444,  444,  444,  444,  444,
 611 |           444,  444,  444,  444,  444,  444,  444,  444,   56,  701,
 612 |           645,  639,  710,  716,  717,  722,  923,  641,  931,  788,
 613 |           790,  522,  791,  798,  799,  803,  804,  787,  815,  961,
 614 |           816,  128,  128,  128,  128,  128,  128,  128,  128,  128,
 615 |           128,  128,  216,  265,   84,  314,  202,  300,  630,  630,
 616 |           630,  630,  630,  630,  421,  421,  421,  421,  421,  421,
 617 |           421,  421,  421,  421,  421,  421,  421,  421,  421,  421,
 618 |           364,  555,  555,  555,  307,  624,  385,  718,  718,  718,
 619 |           718,  718,  718,  718,  718,  718,  718,  718,  718,  718,
 620 |           718,  718,  718,  718,  718,  718,  718,  718,  718,  718,
 621 |           718,  718,  718,  718,  718,  718,  718,  718,  718,  718,
 622 |           718,  718,  718,  718,  718,  718,  718,  718,  718,  179,
 623 |           -18,  -18,  830,  558, 1071,  369,  881,  424,  873,  251,
 624 |           251,  251,  251,  251,  -24,  428,    4,    4,    4,    4,
 625 |           452,  884,  884,  884,  884,  651,  651,  651,  651,  -31,
 626 |           212,  248,   73,   73,  647,  647,  557,  769,  433,  433,
 627 |           439,  439,  975,  975,  975,  975,  975,  975,  975,  975,
 628 |           975,  975,  622,  588,  880,  880,   91,   91,   91,   91,
 629 |           438,  438,  363,  410,  342,   -1,  331,  331,  331,  398,
 630 |           398,  398,  -30,  155,  540,  360,  360,  360,  547,  602,
 631 |           553,  341,  -55,  -55,  -55,  -55,  388,  600,  -55,  -55,
 632 |           -55,  253,  240,   44,   44,  119,  288,  628,  771,  631,
 633 |           786,  466,  655,  172,  661,  661,  661,  199,  613,  422,
 634 |           469,  453,  883,  217,  476,  199,  883,   56,  118,  463,
 635 |           267,  548,  724,  578,  732,  729,   43,   82,   13,  435,
 636 |           236,  215,  209,  730,  731,  933,  935,   92,    3,  644,
 637 |           548,  548,  548,  497,   35,  168,  236,   28,  460,  460,
 638 |           460,  460,  460,  460,  460,  460,  739,  105,   98,  728,
 639 |           279,  566,  825,  583,  587,  598,  817,  583,  627,  566,
 640 |           827,  827,  827,  827,  566,  598,  817,  817,  566,  557,
 641 |            55,  556,  566,  556,  556,  598,  817,  556,  827,  663,
 642 |           664,  556,  583,  623,  610,  617,  817,  556,  587,  556,
 643 |           566,  640,  817,  827,  611,  654,  104,  556,  827,  485,
 644 |           611,  817,  485,  485,  566,  627,  556,  485,   48,  508,
 645 |           543,  826,  828,  876,  582,  660,  607,  616,  845,  846,
 646 |           831,  568,  572,  842,  819,  659,  666,  574,  358,  550,
 647 |           554,  559,  561,  608,  565,  618,  613,  609,  542,  542,
 648 |           542,  612,  646,  612,  542,  542,  542,  542,  542,  542,
 649 |           542,  542,  878,  649,  604,  625,  636,  667,  429,  659,
 650 |           635,  436,  659,  907,  892,  813,  599,  862,  905,  612,
 651 |           934,  605,   62,  451,  637,  601,  612,  863,  612,  740,
 652 |           612,  908,  603,  738,  659,  542,  936,  937,  938,  939,
 653 |           917,  944,  953,  954,  956,  567,  957,  668,  864,  894,
 654 |           175,  835,  606,  648,  619,  672,  744,  958,  612,  620,
 655 |           600,  612,  612,  673,  650,  867,  679,  959,  602,  895,
 656 |           612,  246,  960,  749,  489,  570,  767,  680,  896,  875,
 657 |           626,  922,  874,  750,  614,  770,  246,  493,  684,  872,
 658 |           890,  833,  685,  752,  475,  490,  760,  634,  629,  766,
 659 |           579,  686,  906,  768,  615,  652,  638,  632,  865,  690,
 660 |           621,  694,  900,  695,    0,    0,    0,    0,    0,    0,
 661 |             0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
 662 |             0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
 663 |             0,    0,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,
 664 |            -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,
 665 |            -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,    0,    0,
 666 |             0,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,
 667 |            -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,
 668 |            -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,
 669 |            -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,
 670 |            -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,
 671 |            -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,
 672 |            -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,
 673 |            -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,
 674 |            -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,
 675 |            -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,
 676 |            -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,   -2,  128,
 677 |           128,  128,  128,  128,  128,  128,  128,  128,  128,  128,
 678 |           128,  128,  128,  128,  128,  128,  128,  128,  128,  128,
 679 |           128,  128,    0,    0,    0,    0,    0,    0,    0,    0,
 680 |             0,    0,    0,  128,  -18,  -18,  -18,  -18,  128,  -18,
 681 |           -18,  -18,  -18,  -18,  -18,  128,  128,  128,  128,  128,
 682 |           128,  128,  128,  128,  128,  128,  128,  128,  128,  128,
 683 |           128,  -18,  128,  128,  128,  -18,  975,  -18,  975,  975,
 684 |           975,  975,  975,  975,  975,  975,  975,  975,  975,  975,
 685 |           975,  975,  975,  975,  975,  975,  975,  975,  975,  975,
 686 |           975,  975,  975,  975,  975,  975,  975,  975,  975,  975,
 687 |           975,  975,  975,  975,  975,  975,  975,  975,  975,  975,
 688 |           128,    0,    0,  128,  -18,  128,  -18,  128,  -18,  128,
 689 |           128,  128,  128,  128,  128,  -18,  -18,  -18,  -18,  -18,
 690 |           -18,    0,  331,  331,  331,  331,  -18,  -18,  -18,  -18,
 691 |           156,  156,  156,  975,  975,  975,  975,  975,  975,  331,
 692 |           331,  398,  398,    0,    0,    0,    0,    0,    0,    0,
 693 |             0,    0,    0,  156,  156,  975,  975,  -55,  -55,  -55,
 694 |           -55,  -55,  -55,   44,   44,   44,  215,    0,    0,    0,
 695 |             0,    0,    0,  -55,  598,   44,  275,  275,  275,   44,
 696 |            44,   44,  215,    0,    0,    0,    0,  598,  275,    0,
 697 |             0,    0,  556,  817,    0,    0,    0,  275,  449,  449,
 698 |           449,  449,  246,  236,    0,  598,  598,  598,    0,  623,
 699 |             0,    0,    0,  556,    0,    0,    0,  556,    0,    0,
 700 |             0,    0,  542,   62,  862,  283,  271,    0,    0,    0,
 701 |             0,    0,    0,    0,  271,  271,  295,  295,    0,    0,
 702 |           567,  542,  542,  542,    0,    0,    0,    0,    0,    0,
 703 |             0,    0,    0,    0,    0,    0,    0,  283,    0,    0,
 704 |           246
 705 |     );
 706 | 
 707 |     protected $actionDefault = array(
 708 |             3,32767,32767,    1,32767,32767,32767,32767,32767,32767,
 709 |         32767,32767,32767,32767,32767,32767,  116,  108,  122,  107,
 710 |           118,32767,32767,32767,32767,32767,32767,32767,32767,32767,
 711 |         32767,32767,  429,  429,32767,  386,32767,32767,32767,32767,
 712 |         32767,32767,32767,  193,  193,  193,32767,32767,32767,  418,
 713 |           418,  418,  418,  418,  418,  418,  418,  418,  418,  418,
 714 |         32767,32767,32767,32767,32767,  275,32767,32767,32767,32767,
 715 |         32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
 716 |         32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
 717 |         32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
 718 |         32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
 719 |         32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
 720 |         32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
 721 |         32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
 722 |           280,  434,32767,32767,32767,32767,32767,32767,32767,32767,
 723 |         32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
 724 |         32767,  256,  257,  259,  260,  192,  419,  144,  281,  433,
 725 |           191,  146,  220,  390,32767,32767,32767,  222,   26,  155,
 726 |           100,  389,  131,  190,  274,  221,  197,  202,  203,  204,
 727 |           205,  206,  207,  208,  209,  210,  211,  212,  213,  196,
 728 |           344,  253,  252,  251,  346,32767,  345,  383,  383,  386,
 729 |         32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
 730 |         32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
 731 |         32767,32767,32767,32767,32767,32767,32767,32767,32767,32767,
 732 |         32767,32767,32767,32767,32767,32767,32767,32767,32767,  218,
 733 |           372,  371,  219,  342,  223,  343,  225,  347,  224,  241,
 734 |           242,  239,  240,  243,  349,  348,  365,  366,  363,  364,
 735 |           195,  244,  245,  246,  247,  367,  368,  369,  370,  177,
 736 |           177,  177,32767,32767,  428,  428,32767,32767,  232,  233,
 737 |           356,  357,32767,32767,32767,32767,32767,32767,32767,32767,
 738 |         32767,32767,  178,32767,32767,32767,  135,  135,  135,  135,
 739 |           135,32767,32767,32767,32767,32767,  227,  228,  226,  351,
 740 |           352,  350,32767,32767,  318,32767,32767,32767,32767,32767,
 741 |           320,32767,32767,32767,32767,32767,32767,32767,32767,32767,
 742 |         32767,  375,  391,  319,32767,32767,32767,32767,32767,32767,
 743 |         32767,32767,  404,  307,32767,32767,32767,32767,  300,  119,
 744 |           121,   64,  301,32767,32767,32767,  381,32767,32767,32767,
 745 |           409,  237,32767,32767,32767,32767,32767,32767,  441,32767,
 746 |           404,32767,32767,32767,32767,32767,32767,32767,32767,  250,
 747 |           229,  230,  231,32767,32767,32767,  408,  402,  359,  360,
 748 |           361,  362,  353,  354,  355,  358,32767,32767,32767,32767,
 749 |         32767,   68,  315,32767,32767,32767,  321,32767,32767,   68,
 750 |         32767,32767,32767,32767,   68,32767,  407,  406,   68,32767,
 751 |           385,   76,   68,   76,   76,32767,32767,   76,32767,  105,
 752 |           105,   76,32767,32767,   86,   84,  397,   76,32767,   76,
 753 |            68,   88,32767,32767,  289,   70,  385,   76,32767,  137,
 754 |           289,32767,  137,  137,   68,32767,   76,  137,32767,    4,
 755 |           325,32767,32767,32767,32767,32767,32767,32767,32767,32767,
 756 |         32767,32767,32767,32767,32767,  302,32767,32767,32767,  271,
 757 |           272,  378,  393,32767,  394,32767,  300,32767,  235,  236,
 758 |           238,  215,32767,  217,  261,  262,  263,  264,  265,  266,
 759 |           267,  269,32767,32767,  305,  308,32767,32767,32767,    6,
 760 |            20,  154,  303,32767,  200,32767,32767,32767,32767,  436,
 761 |         32767,32767,  194,32767,   22,32767,  150,32767,   66,32767,
 762 |           426,32767,32767,  402,  304,  234,32767,32767,32767,32767,
 763 |         32767,32767,32767,32767,32767,  403,32767,32767,32767,32767,
 764 |           126,32767,  338,32767,32767,32767,32767,32767,  198,32767,
 765 |         32767,  145,  435,32767,32767,32767,32767,32767,32767,32767,
 766 |            67,   87,32767,32767,32767,32767,  402,32767,32767,32767,
 767 |         32767,32767,32767,32767,32767,32767,   89,32767,32767,32767,
 768 |         32767,  402,32767,32767,  130,  189,32767,32767,32767,32767,
 769 |         32767,32767,32767,32767,    4,32767,  171,32767,32767,32767,
 770 |         32767,32767,32767,32767,   28,   28,    3,   28,  113,   28,
 771 |             3,  105,  105,   61,  157,   28,  157,   28,  157,   28,
 772 |            28,   28,   28,   28,   28,  164,   28,   28,   28,   28,
 773 |            28
 774 |     );
 775 | 
 776 |     protected $goto = array(
 777 |           167,  167,  141,  141,  146,  141,  142,  143,  144,  149,
 778 |           151,  186,  169,  165,  165,  165,  165,  146,  146,  166,
 779 |           166,  166,  166,  166,  166,  166,  166,  166,  166,  166,
 780 |           161,  162,  163,  164,  184,  140,  498,  499,  371,  500,
 781 |           504,  505,  506,  507,  508,  509,  510,  511,  852,  145,
 782 |           147,  148,  150,  172,  177,  185,  201,  249,  252,  254,
 783 |           256,  258,  259,  260,  261,  262,  263,  271,  272,  273,
 784 |           274,  288,  289,  316,  317,  318,  390,  391,  392,  545,
 785 |           187,  188,  189,  190,  191,  192,  193,  194,  195,  196,
 786 |           197,  198,  199,  152,  153,  154,  168,  155,  170,  156,
 787 |           202,  157,  171,  158,  159,  203,  160,  138,  562,  705,
 788 |           562,  562,  562,  562,  562,  562,  562,  562,  562,  562,
 789 |           562,  562,  562,  562,  562,  562,  562,  562,  562,  562,
 790 |           562,  562,  562,  562,  562,  562,  562,  562,  562,  562,
 791 |           562,  562,  562,  562,  562,  562,  562,  562,  562,  562,
 792 |           562,  562,  502,  502,  502,  502,  502,  502, 1057, 1057,
 793 |           379,  794,  502,  502,  502,  502,  502,  502,  502,  502,
 794 |           502,  502,  606,  609,  513,  513,  280,  369,  281, 1073,
 795 |          1073, 1073,  659,  659,  659,  362,  362,  362,  362,  362,
 796 |           362, 1056,  574,  599,  524,  362,  362,  362,  362,  362,
 797 |           362,  362,  362,  362,  362, 1058, 1058,  952,  952,  449,
 798 |           449,  449,  449,  449,  449,  546,  547,  548,  549,  551,
 799 |           552,  553,  554,  556,  582,  615,  776,  776, 1078, 1078,
 800 |           660,  660,  660,  831,  410,  741,  741,  741,  741,  534,
 801 |           541,  736,  742,  608,  563, 1082,  563,  563,  563,  563,
 802 |           563,  563,  563,  563,  563,  563,  563,  563,  563,  563,
 803 |           563,  563,  563,  563,  563,  563,  563,  563,  563,  563,
 804 |           563,  563,  563,  563,  563,  563,  563,  563,  563,  563,
 805 |           563,  563,  563,  563,  563,  563,  563,  563,  987,  372,
 806 |           987,  987,  987,  987,  987,  987,  987,  987,  987,  987,
 807 |           987,  987,  987,  987,  987,  987,  987,  987,  987,  987,
 808 |           987,  987,  987,  987,  987,  987,  987,  987,  987,  987,
 809 |           987,  987,  987,  987,  987,  987,  987,  987,  987,  987,
 810 |           987,  987,  963,  962,  348,  579,  588,  622,  330,  591,
 811 |           175, 1038,  314,  514,  514,  178,  179,  180,  398,  399,
 812 |           400,  401,  174,  200,  204,  206,  253,  255,  257,  264,
 813 |           265,  266,  267,  268,  269,  275,  276,  277,  278,  290,
 814 |           291,  319,  320,  321,  402,  403,  404,  405,  176,  181,
 815 |           250,  251,  182,  183,    5,  452,   16,  600,    6,    1,
 816 |           596,  351,  409,    2,    7, 1075,   17,  899,   18,    8,
 817 |            19,    9,   20,   10,  386,   11,   12,   13,   14,   15,
 818 |           397,  601,  540,  540,  568,  536,  658,  658,  658,  789,
 819 |           538,  538,  501,  503,  529,  543,  571,  572,  580,  586,
 820 |           780,  550,  519,  850,  669,  523,  762,  747,  745,  743,
 821 |           745,  628,  516,  771,  766,  519,  798,  973,  523,  523,
 822 |           416,  406,  539,  444,  515,  515,  445,  948,  949,  988,
 823 |           558,  968,  637,  519,  519,  519,  452,  945,  783,  909,
 824 |            26,   21,  363, 1088, 1088,  675,  461, 1049,  383,  384,
 825 |           373,  943, 1035,  946,  527,  618,  803,  557,  537, 1091,
 826 |          1088,    0,  947,  380,  380,  380,  750,  463,    0,    0,
 827 |           839,    0,   29, 1091, 1091,  380,  455,  597,    0,    0,
 828 |             0,    0,    0,    0,  396,    0,    0,    0,    0,    0,
 829 |           610,    0,    0,    0,  519,  349,  350,    0,    0,    0,
 830 |             0,    0,    0,    0,  522,    0,    0,    0,    0,    0,
 831 |             0,    0,    0,    0,  544,    0,    0,    0,    0,    0,
 832 |             0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
 833 |             0,    0,    0,    0,    0,    0,    0,    0,    0,    0,
 834 |             0,    0,    0,    0,    0,    0,  528
 835 |     );
 836 | 
 837 |     protected $gotoCheck = array(
 838 |            25,   25,   25,   25,   25,   25,   25,   25,   25,   25,
 839 |            25,   25,   25,   25,   25,   25,   25,   25,   25,   25,
 840 |            25,   25,   25,   25,   25,   25,   25,   25,   25,   25,
 841 |            25,   25,   25,   25,   25,   25,   25,   25,   25,   25,
 842 |            25,   25,   25,   25,   25,   25,   25,   25,   25,   25,
 843 |            25,   25,   25,   25,   25,   25,   25,   25,   25,   25,
 844 |            25,   25,   25,   25,   25,   25,   25,   25,   25,   25,
 845 |            25,   25,   25,   25,   25,   25,   25,   25,   25,   25,
 846 |            25,   25,   25,   25,   25,   25,   25,   25,   25,   25,
 847 |            25,   25,   25,   25,   25,   25,   25,   25,   25,   25,
 848 |            25,   25,   25,   25,   25,   25,   25,   25,   39,   32,
 849 |            39,   39,   39,   39,   39,   39,   39,   39,   39,   39,
 850 |            39,   39,   39,   39,   39,   39,   39,   39,   39,   39,
 851 |            39,   39,   39,   39,   39,   39,   39,   39,   39,   39,
 852 |            39,   39,   39,   39,   39,   39,   39,   39,   39,   39,
 853 |            39,   39,   96,   96,   96,   96,   96,   96,   98,   98,
 854 |             5,   65,   96,   96,   96,   96,   96,   96,   96,   96,
 855 |            96,   96,   44,   44,   96,   96,   48,   44,   48,   98,
 856 |            98,   98,    7,    7,    7,   39,   39,   39,   39,   39,
 857 |            39,   98,   22,   22,   81,   39,   39,   39,   39,   39,
 858 |            39,   39,   39,   39,   39,   97,   97,   39,   39,   39,
 859 |            39,   39,   39,   39,   39,   90,   90,   90,   90,   90,
 860 |            90,   90,   90,   90,   90,   39,   58,   58,   58,   58,
 861 |             8,    8,    8,   78,   78,   39,   39,   39,   39,    5,
 862 |            89,   39,   39,   39,   99,  120,   99,   99,   99,   99,
 863 |            99,   99,   99,   99,   99,   99,   99,   99,   99,   99,
 864 |            99,   99,   99,   99,   99,   99,   99,   99,   99,   99,
 865 |            99,   99,   99,   99,   99,   99,   99,   99,   99,   99,
 866 |            99,   99,   99,   99,   99,   99,   99,   99,  106,   29,
 867 |           106,  106,  106,  106,  106,  106,  106,  106,  106,  106,
 868 |           106,  106,  106,  106,  106,  106,  106,  106,  106,  106,
 869 |           106,  106,  106,  106,  106,  106,  106,  106,  106,  106,
 870 |           106,  106,  106,  106,  106,  106,  106,  106,  106,  106,
 871 |           106,  106,  104,  104,   53,   43,   43,   43,  105,  108,
 872 |            13,  112,  105,   99,   99,   13,   13,   13,   13,   13,
 873 |            13,   13,   13,   13,   13,   13,   13,   13,   13,   13,
 874 |            13,   13,   13,   13,   13,   13,   13,   13,   13,   13,
 875 |            13,   13,   13,   13,   13,   13,   13,   13,   13,   13,
 876 |            13,   13,   13,   13,   14,   42,   14,   31,   14,    2,
 877 |            51,   51,   51,    2,   14,  118,   14,   82,   14,   14,
 878 |            14,   14,   14,   14,   30,   14,   14,   14,   14,   14,
 879 |            33,   33,   33,   33,   33,   33,    6,    6,    6,   62,
 880 |            33,   33,   33,   33,   33,   33,   33,   33,   33,   33,
 881 |            60,   26,    4,   81,   11,   26,    6,    6,    6,    6,
 882 |             6,    6,    6,    6,    6,    4,   66,   63,   26,   26,
 883 |            42,   10,   42,   42,  102,  102,   42,   63,   63,  107,
 884 |            42,   16,   55,    4,    4,    4,   42,   63,   42,   16,
 885 |            16,   16,   16,  121,  121,   12,   42,   63,    9,    9,
 886 |            40,   94,  111,   63,   40,   42,   67,   16,   40,  121,
 887 |           121,   -1,   63,  103,  103,  103,   52,   88,   -1,   -1,
 888 |            80,   -1,   16,  121,  121,  103,   40,   16,   -1,   -1,
 889 |            -1,   -1,   -1,   -1,  103,   -1,   -1,   -1,   -1,   -1,
 890 |            40,   -1,   -1,   -1,    4,   53,   53,   -1,   -1,   -1,
 891 |            -1,   -1,   -1,   -1,    4,   -1,   -1,   -1,   -1,   -1,
 892 |            -1,   -1,   -1,   -1,    4,   -1,   -1,   -1,   -1,   -1,
 893 |            -1,   -1,   -1,   -1,   -1,   -1,   -1,   -1,   -1,   -1,
 894 |            -1,   -1,   -1,   -1,   -1,   -1,   -1,   -1,   -1,   -1,
 895 |            -1,   -1,   -1,   -1,   -1,   -1,   81
 896 |     );
 897 | 
 898 |     protected $gotoBase = array(
 899 |             0,    0, -237,    0,  109, -176,  415,  181,  229,  124,
 900 |            34,   78,   33,  135, -241,    0,   49,    0,    0,    0,
 901 |             0,    0,  148,    0,    0,  -30,  401,    0,    0,  243,
 902 |           111,  104,   84,  128,    0,    0,    0,    0,    0,  -97,
 903 |            56,    0,   19,   28, -290,    0,    0,    0, -460,    0,
 904 |             0,   57,   48, -106,    0,   95,    0,    0,  -56,    0,
 905 |           120,    0,  108,   31,    0,  130,   81,   43,    0,    0,
 906 |             0,    0,    0,    0,    0,    0,    0,    0,  -69,    0,
 907 |            35,  147,   92,    0,    0,    0,    0,    0,   37,  207,
 908 |           165,    0,    0,    0,   62,    0, -130,  -99, -146,   39,
 909 |             0,    0,  150,  168,    6,   14,   83,   91,  131,    0,
 910 |             0,   26,  132,    0,    0,    0,    0,    0,  110,    0,
 911 |           210,  160,    0
 912 |     );
 913 | 
 914 |     protected $gotoDefault = array(
 915 |         -32768,  468,    3,  653,  485,  520,  680,  681,  682,  375,
 916 |           374,  670,  676,  173,    4,  678,  900,  359,  685,  360,
 917 |           585,  687,  531,  689,  690,  139,  486,  376,  377,  532,
 918 |           385,  575,  704,  270,  382,  706,  361,  708,  713,  341,
 919 |           607,  590,  436,  559,  603,  487,  451,  583,  279,  566,
 920 |           393,  581,  749,  347,  757,  641,  765,  768,  488,  560,
 921 |           779,  450,  787, 1050,  394,  793,  799,  804,  807,  418,
 922 |           407,  594,  811,  812,  322,  816,  616,  617,  830,  302,
 923 |           838,  851,  431,  919,  921,  489,  490,  525,  459,  512,
 924 |           530,  491,  939,  408,  942,  492,  493,  426,  427,  960,
 925 |           957,  353, 1043,  352,  446,  313, 1028, 1027,  577,  992,
 926 |           456, 1081, 1039,  342,  494,  495,  370,  387, 1076,  430,
 927 |          1083, 1090,  567
 928 |     );
 929 | 
 930 |     protected $ruleToNonTerminal = array(
 931 |             0,    1,    2,    2,    4,    4,    5,    3,    3,    3,
 932 |             3,    3,    3,    3,    3,    3,    3,    3,    9,    9,
 933 |            11,   11,   11,   11,   10,   10,   12,   14,   14,   15,
 934 |            15,   15,   15,    6,    6,    6,    6,    6,    6,    6,
 935 |             6,    6,    6,    6,    6,    6,    6,    6,    6,    6,
 936 |             6,    6,    6,    6,    6,    6,    6,    6,    6,    6,
 937 |             6,   36,   36,   38,   37,   37,   30,   30,   40,   40,
 938 |            41,   41,    7,    8,    8,    8,   42,   42,   42,   50,
 939 |            50,   45,   45,   45,   46,   46,   49,   49,   47,   47,
 940 |            51,   51,   23,   23,   32,   32,   35,   35,   34,   34,
 941 |            52,   24,   24,   24,   24,   53,   53,   54,   54,   55,
 942 |            55,   21,   21,   17,   17,   56,   19,   19,   57,   18,
 943 |            18,   20,   20,   31,   31,   31,   43,   43,   59,   59,
 944 |            60,   60,   62,   62,   62,   61,   61,   44,   44,   63,
 945 |            63,   63,   64,   64,   65,   65,   65,   27,   27,   66,
 946 |            66,   66,   28,   28,   67,   67,   48,   48,   68,   68,
 947 |            68,   68,   73,   73,   74,   74,   75,   75,   75,   75,
 948 |            76,   77,   77,   72,   72,   69,   69,   71,   71,   79,
 949 |            79,   78,   78,   78,   78,   78,   78,   70,   70,   80,
 950 |            80,   29,   29,   22,   22,   25,   25,   25,   25,   25,
 951 |            25,   25,   25,   25,   25,   25,   25,   25,   25,   25,
 952 |            25,   25,   25,   25,   25,   25,   25,   25,   25,   25,
 953 |            25,   25,   25,   25,   25,   25,   25,   25,   25,   25,
 954 |            25,   25,   25,   25,   25,   25,   25,   25,   25,   25,
 955 |            25,   25,   25,   25,   25,   25,   25,   25,   25,   25,
 956 |            25,   25,   25,   25,   25,   25,   25,   25,   25,   25,
 957 |            25,   25,   25,   25,   25,   25,   25,   25,   25,   25,
 958 |            25,   25,   25,   25,   25,   25,   25,   25,   16,   16,
 959 |            26,   26,   85,   85,   86,   86,   86,   86,   81,   88,
 960 |            88,   93,   93,   94,   95,   95,   95,   95,   95,   95,
 961 |            99,   99,   39,   39,   39,   82,   82,  100,  100,   96,
 962 |            96,  101,  101,  101,  101,   83,   83,   83,   87,   87,
 963 |            87,   92,   92,  106,  106,  106,  106,  106,  106,  106,
 964 |           106,  106,  106,  106,  106,  106,   13,   13,   13,   13,
 965 |            13,   13,  109,  109,  109,  109,  109,  109,  109,  109,
 966 |           109,  109,  109,  109,  109,  109,  109,  109,  109,  109,
 967 |           109,  109,  109,  109,  109,  109,  109,  109,  109,  109,
 968 |           109,  109,  109,  109,  109,   91,   91,   84,   84,   84,
 969 |            84,  107,  107,  108,  108,  111,  111,  110,  110,  112,
 970 |           112,   33,   33,   33,   33,  114,  114,  113,  113,  113,
 971 |           113,  113,  115,  115,   98,   98,  102,  102,   97,   97,
 972 |           116,  116,  116,  116,  103,  103,  103,  103,   90,   90,
 973 |           104,  104,  104,   58,  117,  117,  118,  118,  118,   89,
 974 |            89,  119,  119,  120,  120,  120,  120,  105,  105,  105,
 975 |           105,  121,  121,  121,  121,  121,  121,  121,  122,  122,
 976 |           122
 977 |     );
 978 | 
 979 |     protected $ruleToLength = array(
 980 |             1,    1,    2,    0,    1,    3,    1,    1,    1,    1,
 981 |             1,    3,    5,    4,    3,    4,    4,    3,    3,    1,
 982 |             1,    3,    2,    4,    3,    1,    3,    2,    0,    1,
 983 |             1,    1,    1,    3,    5,    8,    3,    5,    9,    3,
 984 |             2,    3,    2,    3,    2,    3,    2,    3,    3,    3,
 985 |             1,    2,    5,    7,    9,    5,    1,    6,    3,    3,
 986 |             2,    0,    2,    8,    0,    4,    1,    3,    0,    1,
 987 |             0,    1,   11,    8,    7,    6,    0,    2,    3,    1,
 988 |             3,    1,    2,    2,    0,    2,    0,    2,    0,    2,
 989 |             1,    3,    1,    4,    1,    4,    1,    4,    1,    3,
 990 |             3,    3,    4,    4,    5,    0,    2,    4,    3,    1,
 991 |             1,    1,    4,    0,    2,    3,    0,    2,    4,    0,
 992 |             2,    0,    3,    1,    2,    1,    1,    0,    1,    3,
 993 |             4,    6,    2,    1,    1,    0,    1,    0,    2,    2,
 994 |             3,    3,    1,    3,    1,    2,    2,    3,    1,    1,
 995 |             2,    4,    3,    1,    1,    3,    2,    0,    3,    3,
 996 |            10,    3,    1,    3,    0,    2,    4,    5,    4,    4,
 997 |             3,    1,    1,    1,    3,    1,    1,    0,    1,    1,
 998 |             2,    1,    1,    1,    1,    1,    1,    1,    3,    1,
 999 |             3,    3,    1,    0,    1,    1,    3,    3,    4,    4,
1000 |             1,    2,    3,    3,    3,    3,    3,    3,    3,    3,
1001 |             3,    3,    3,    3,    2,    2,    2,    2,    3,    3,
1002 |             3,    3,    3,    3,    3,    3,    3,    3,    3,    3,
1003 |             3,    3,    3,    3,    3,    2,    2,    2,    2,    3,
1004 |             3,    3,    3,    3,    3,    3,    3,    3,    3,    1,
1005 |             3,    5,    4,    3,    4,    4,    2,    2,    2,    2,
1006 |             2,    2,    2,    2,    2,    2,    2,    2,    2,    2,
1007 |             1,    1,    1,    3,    2,    1,   10,   11,    3,    3,
1008 |             2,    4,    4,    3,    4,    4,    4,    4,    4,    0,
1009 |             4,    1,    3,    2,    3,    5,    7,    2,    2,    4,
1010 |             1,    1,    1,    2,    3,    1,    1,    1,    1,    1,
1011 |             1,    3,    3,    4,    4,    0,    2,    1,    0,    1,
1012 |             1,    0,    1,    1,    1,    1,    1,    1,    1,    1,
1013 |             1,    1,    1,    1,    3,    2,    1,    3,    1,    4,
1014 |             3,    1,    3,    3,    3,    3,    3,    3,    3,    3,
1015 |             3,    3,    3,    3,    3,    3,    3,    3,    3,    2,
1016 |             2,    2,    2,    3,    3,    3,    3,    3,    3,    3,
1017 |             3,    5,    4,    4,    3,    1,    3,    1,    1,    3,
1018 |             3,    1,    1,    0,    2,    0,    1,    3,    1,    3,
1019 |             1,    1,    1,    1,    1,    6,    4,    3,    4,    2,
1020 |             4,    4,    1,    3,    1,    2,    1,    1,    4,    1,
1021 |             3,    6,    4,    4,    4,    4,    1,    4,    0,    1,
1022 |             1,    3,    1,    4,    3,    1,    1,    1,    0,    0,
1023 |             2,    3,    1,    3,    1,    4,    2,    2,    2,    1,
1024 |             2,    1,    4,    3,    3,    3,    6,    3,    1,    1,
1025 |             1
1026 |     );
1027 | 
1028 |     protected function reduceRule0() {
1029 |         $this->semValue = $this->semStack[$this->stackPos];
1030 |     }
1031 | 
1032 |     protected function reduceRule1($attributes) {
1033 |          $this->semValue = $this->handleNamespaces($this->semStack[$this->stackPos-(1-1)]); 
1034 |     }
1035 | 
1036 |     protected function reduceRule2($attributes) {
1037 |          if (is_array($this->semStack[$this->stackPos-(2-2)])) { $this->semValue = array_merge($this->semStack[$this->stackPos-(2-1)], $this->semStack[$this->stackPos-(2-2)]); } else { $this->semStack[$this->stackPos-(2-1)][] = $this->semStack[$this->stackPos-(2-2)]; $this->semValue = $this->semStack[$this->stackPos-(2-1)]; }; 
1038 |     }
1039 | 
1040 |     protected function reduceRule3($attributes) {
1041 |          $this->semValue = array(); 
1042 |     }
1043 | 
1044 |     protected function reduceRule4($attributes) {
1045 |          $this->semValue = array($this->semStack[$this->stackPos-(1-1)]); 
1046 |     }
1047 | 
1048 |     protected function reduceRule5($attributes) {
1049 |          $this->semStack[$this->stackPos-(3-1)][] = $this->semStack[$this->stackPos-(3-3)]; $this->semValue = $this->semStack[$this->stackPos-(3-1)]; 
1050 |     }
1051 | 
1052 |     protected function reduceRule6($attributes) {
1053 |          $this->semValue = new Node\Name($this->semStack[$this->stackPos-(1-1)], $attributes); 
1054 |     }
1055 | 
1056 |     protected function reduceRule7($attributes) {
1057 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
1058 |     }
1059 | 
1060 |     protected function reduceRule8($attributes) {
1061 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
1062 |     }
1063 | 
1064 |     protected function reduceRule9($attributes) {
1065 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
1066 |     }
1067 | 
1068 |     protected function reduceRule10($attributes) {
1069 |          $this->semValue = new Node\Stmt\HaltCompiler($this->lexer->handleHaltCompiler(), $attributes); 
1070 |     }
1071 | 
1072 |     protected function reduceRule11($attributes) {
1073 |          $this->semValue = new Node\Stmt\Namespace_($this->semStack[$this->stackPos-(3-2)], null, $attributes); 
1074 |     }
1075 | 
1076 |     protected function reduceRule12($attributes) {
1077 |          $this->semValue = new Node\Stmt\Namespace_($this->semStack[$this->stackPos-(5-2)], $this->semStack[$this->stackPos-(5-4)], $attributes); 
1078 |     }
1079 | 
1080 |     protected function reduceRule13($attributes) {
1081 |          $this->semValue = new Node\Stmt\Namespace_(null, $this->semStack[$this->stackPos-(4-3)], $attributes); 
1082 |     }
1083 | 
1084 |     protected function reduceRule14($attributes) {
1085 |          $this->semValue = new Node\Stmt\Use_($this->semStack[$this->stackPos-(3-2)], Node\Stmt\Use_::TYPE_NORMAL, $attributes); 
1086 |     }
1087 | 
1088 |     protected function reduceRule15($attributes) {
1089 |          $this->semValue = new Node\Stmt\Use_($this->semStack[$this->stackPos-(4-3)], Node\Stmt\Use_::TYPE_FUNCTION, $attributes); 
1090 |     }
1091 | 
1092 |     protected function reduceRule16($attributes) {
1093 |          $this->semValue = new Node\Stmt\Use_($this->semStack[$this->stackPos-(4-3)], Node\Stmt\Use_::TYPE_CONSTANT, $attributes); 
1094 |     }
1095 | 
1096 |     protected function reduceRule17($attributes) {
1097 |          $this->semValue = new Node\Stmt\Const_($this->semStack[$this->stackPos-(3-2)], $attributes); 
1098 |     }
1099 | 
1100 |     protected function reduceRule18($attributes) {
1101 |          $this->semStack[$this->stackPos-(3-1)][] = $this->semStack[$this->stackPos-(3-3)]; $this->semValue = $this->semStack[$this->stackPos-(3-1)]; 
1102 |     }
1103 | 
1104 |     protected function reduceRule19($attributes) {
1105 |          $this->semValue = array($this->semStack[$this->stackPos-(1-1)]); 
1106 |     }
1107 | 
1108 |     protected function reduceRule20($attributes) {
1109 |          $this->semValue = new Node\Stmt\UseUse($this->semStack[$this->stackPos-(1-1)], null, $attributes); 
1110 |     }
1111 | 
1112 |     protected function reduceRule21($attributes) {
1113 |          $this->semValue = new Node\Stmt\UseUse($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1114 |     }
1115 | 
1116 |     protected function reduceRule22($attributes) {
1117 |          $this->semValue = new Node\Stmt\UseUse($this->semStack[$this->stackPos-(2-2)], null, $attributes); 
1118 |     }
1119 | 
1120 |     protected function reduceRule23($attributes) {
1121 |          $this->semValue = new Node\Stmt\UseUse($this->semStack[$this->stackPos-(4-2)], $this->semStack[$this->stackPos-(4-4)], $attributes); 
1122 |     }
1123 | 
1124 |     protected function reduceRule24($attributes) {
1125 |          $this->semStack[$this->stackPos-(3-1)][] = $this->semStack[$this->stackPos-(3-3)]; $this->semValue = $this->semStack[$this->stackPos-(3-1)]; 
1126 |     }
1127 | 
1128 |     protected function reduceRule25($attributes) {
1129 |          $this->semValue = array($this->semStack[$this->stackPos-(1-1)]); 
1130 |     }
1131 | 
1132 |     protected function reduceRule26($attributes) {
1133 |          $this->semValue = new Node\Const_($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1134 |     }
1135 | 
1136 |     protected function reduceRule27($attributes) {
1137 |          if (is_array($this->semStack[$this->stackPos-(2-2)])) { $this->semValue = array_merge($this->semStack[$this->stackPos-(2-1)], $this->semStack[$this->stackPos-(2-2)]); } else { $this->semStack[$this->stackPos-(2-1)][] = $this->semStack[$this->stackPos-(2-2)]; $this->semValue = $this->semStack[$this->stackPos-(2-1)]; }; 
1138 |     }
1139 | 
1140 |     protected function reduceRule28($attributes) {
1141 |          $this->semValue = array(); 
1142 |     }
1143 | 
1144 |     protected function reduceRule29($attributes) {
1145 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
1146 |     }
1147 | 
1148 |     protected function reduceRule30($attributes) {
1149 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
1150 |     }
1151 | 
1152 |     protected function reduceRule31($attributes) {
1153 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
1154 |     }
1155 | 
1156 |     protected function reduceRule32($attributes) {
1157 |          throw new Error('__HALT_COMPILER() can only be used from the outermost scope'); 
1158 |     }
1159 | 
1160 |     protected function reduceRule33($attributes) {
1161 |          $this->semValue = $this->semStack[$this->stackPos-(3-2)]; 
1162 |     }
1163 | 
1164 |     protected function reduceRule34($attributes) {
1165 |          $this->semValue = new Node\Stmt\If_($this->semStack[$this->stackPos-(5-2)], array('stmts' => is_array($this->semStack[$this->stackPos-(5-3)]) ? $this->semStack[$this->stackPos-(5-3)] : array($this->semStack[$this->stackPos-(5-3)]), 'elseifs' => $this->semStack[$this->stackPos-(5-4)], 'else' => $this->semStack[$this->stackPos-(5-5)]), $attributes); 
1166 |     }
1167 | 
1168 |     protected function reduceRule35($attributes) {
1169 |          $this->semValue = new Node\Stmt\If_($this->semStack[$this->stackPos-(8-2)], array('stmts' => $this->semStack[$this->stackPos-(8-4)], 'elseifs' => $this->semStack[$this->stackPos-(8-5)], 'else' => $this->semStack[$this->stackPos-(8-6)]), $attributes); 
1170 |     }
1171 | 
1172 |     protected function reduceRule36($attributes) {
1173 |          $this->semValue = new Node\Stmt\While_($this->semStack[$this->stackPos-(3-2)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1174 |     }
1175 | 
1176 |     protected function reduceRule37($attributes) {
1177 |          $this->semValue = new Node\Stmt\Do_($this->semStack[$this->stackPos-(5-4)], is_array($this->semStack[$this->stackPos-(5-2)]) ? $this->semStack[$this->stackPos-(5-2)] : array($this->semStack[$this->stackPos-(5-2)]), $attributes); 
1178 |     }
1179 | 
1180 |     protected function reduceRule38($attributes) {
1181 |          $this->semValue = new Node\Stmt\For_(array('init' => $this->semStack[$this->stackPos-(9-3)], 'cond' => $this->semStack[$this->stackPos-(9-5)], 'loop' => $this->semStack[$this->stackPos-(9-7)], 'stmts' => $this->semStack[$this->stackPos-(9-9)]), $attributes); 
1182 |     }
1183 | 
1184 |     protected function reduceRule39($attributes) {
1185 |          $this->semValue = new Node\Stmt\Switch_($this->semStack[$this->stackPos-(3-2)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1186 |     }
1187 | 
1188 |     protected function reduceRule40($attributes) {
1189 |          $this->semValue = new Node\Stmt\Break_(null, $attributes); 
1190 |     }
1191 | 
1192 |     protected function reduceRule41($attributes) {
1193 |          $this->semValue = new Node\Stmt\Break_($this->semStack[$this->stackPos-(3-2)], $attributes); 
1194 |     }
1195 | 
1196 |     protected function reduceRule42($attributes) {
1197 |          $this->semValue = new Node\Stmt\Continue_(null, $attributes); 
1198 |     }
1199 | 
1200 |     protected function reduceRule43($attributes) {
1201 |          $this->semValue = new Node\Stmt\Continue_($this->semStack[$this->stackPos-(3-2)], $attributes); 
1202 |     }
1203 | 
1204 |     protected function reduceRule44($attributes) {
1205 |          $this->semValue = new Node\Stmt\Return_(null, $attributes); 
1206 |     }
1207 | 
1208 |     protected function reduceRule45($attributes) {
1209 |          $this->semValue = new Node\Stmt\Return_($this->semStack[$this->stackPos-(3-2)], $attributes); 
1210 |     }
1211 | 
1212 |     protected function reduceRule46($attributes) {
1213 |          $this->semValue = $this->semStack[$this->stackPos-(2-1)]; 
1214 |     }
1215 | 
1216 |     protected function reduceRule47($attributes) {
1217 |          $this->semValue = new Node\Stmt\Global_($this->semStack[$this->stackPos-(3-2)], $attributes); 
1218 |     }
1219 | 
1220 |     protected function reduceRule48($attributes) {
1221 |          $this->semValue = new Node\Stmt\Static_($this->semStack[$this->stackPos-(3-2)], $attributes); 
1222 |     }
1223 | 
1224 |     protected function reduceRule49($attributes) {
1225 |          $this->semValue = new Node\Stmt\Echo_($this->semStack[$this->stackPos-(3-2)], $attributes); 
1226 |     }
1227 | 
1228 |     protected function reduceRule50($attributes) {
1229 |          $this->semValue = new Node\Stmt\InlineHTML($this->semStack[$this->stackPos-(1-1)], $attributes); 
1230 |     }
1231 | 
1232 |     protected function reduceRule51($attributes) {
1233 |          $this->semValue = $this->semStack[$this->stackPos-(2-1)]; 
1234 |     }
1235 | 
1236 |     protected function reduceRule52($attributes) {
1237 |          $this->semValue = new Node\Stmt\Unset_($this->semStack[$this->stackPos-(5-3)], $attributes); 
1238 |     }
1239 | 
1240 |     protected function reduceRule53($attributes) {
1241 |          $this->semValue = new Node\Stmt\Foreach_($this->semStack[$this->stackPos-(7-3)], $this->semStack[$this->stackPos-(7-5)][0], array('keyVar' => null, 'byRef' => $this->semStack[$this->stackPos-(7-5)][1], 'stmts' => $this->semStack[$this->stackPos-(7-7)]), $attributes); 
1242 |     }
1243 | 
1244 |     protected function reduceRule54($attributes) {
1245 |          $this->semValue = new Node\Stmt\Foreach_($this->semStack[$this->stackPos-(9-3)], $this->semStack[$this->stackPos-(9-7)][0], array('keyVar' => $this->semStack[$this->stackPos-(9-5)], 'byRef' => $this->semStack[$this->stackPos-(9-7)][1], 'stmts' => $this->semStack[$this->stackPos-(9-9)]), $attributes); 
1246 |     }
1247 | 
1248 |     protected function reduceRule55($attributes) {
1249 |          $this->semValue = new Node\Stmt\Declare_($this->semStack[$this->stackPos-(5-3)], $this->semStack[$this->stackPos-(5-5)], $attributes); 
1250 |     }
1251 | 
1252 |     protected function reduceRule56($attributes) {
1253 |          $this->semValue = array(); /* means: no statement */ 
1254 |     }
1255 | 
1256 |     protected function reduceRule57($attributes) {
1257 |          $this->semValue = new Node\Stmt\TryCatch($this->semStack[$this->stackPos-(6-3)], $this->semStack[$this->stackPos-(6-5)], $this->semStack[$this->stackPos-(6-6)], $attributes); 
1258 |     }
1259 | 
1260 |     protected function reduceRule58($attributes) {
1261 |          $this->semValue = new Node\Stmt\Throw_($this->semStack[$this->stackPos-(3-2)], $attributes); 
1262 |     }
1263 | 
1264 |     protected function reduceRule59($attributes) {
1265 |          $this->semValue = new Node\Stmt\Goto_($this->semStack[$this->stackPos-(3-2)], $attributes); 
1266 |     }
1267 | 
1268 |     protected function reduceRule60($attributes) {
1269 |          $this->semValue = new Node\Stmt\Label($this->semStack[$this->stackPos-(2-1)], $attributes); 
1270 |     }
1271 | 
1272 |     protected function reduceRule61($attributes) {
1273 |          $this->semValue = array(); 
1274 |     }
1275 | 
1276 |     protected function reduceRule62($attributes) {
1277 |          $this->semStack[$this->stackPos-(2-1)][] = $this->semStack[$this->stackPos-(2-2)]; $this->semValue = $this->semStack[$this->stackPos-(2-1)]; 
1278 |     }
1279 | 
1280 |     protected function reduceRule63($attributes) {
1281 |          $this->semValue = new Node\Stmt\Catch_($this->semStack[$this->stackPos-(8-3)], substr($this->semStack[$this->stackPos-(8-4)], 1), $this->semStack[$this->stackPos-(8-7)], $attributes); 
1282 |     }
1283 | 
1284 |     protected function reduceRule64($attributes) {
1285 |          $this->semValue = null; 
1286 |     }
1287 | 
1288 |     protected function reduceRule65($attributes) {
1289 |          $this->semValue = $this->semStack[$this->stackPos-(4-3)]; 
1290 |     }
1291 | 
1292 |     protected function reduceRule66($attributes) {
1293 |          $this->semValue = array($this->semStack[$this->stackPos-(1-1)]); 
1294 |     }
1295 | 
1296 |     protected function reduceRule67($attributes) {
1297 |          $this->semStack[$this->stackPos-(3-1)][] = $this->semStack[$this->stackPos-(3-3)]; $this->semValue = $this->semStack[$this->stackPos-(3-1)]; 
1298 |     }
1299 | 
1300 |     protected function reduceRule68($attributes) {
1301 |          $this->semValue = false; 
1302 |     }
1303 | 
1304 |     protected function reduceRule69($attributes) {
1305 |          $this->semValue = true; 
1306 |     }
1307 | 
1308 |     protected function reduceRule70($attributes) {
1309 |          $this->semValue = false; 
1310 |     }
1311 | 
1312 |     protected function reduceRule71($attributes) {
1313 |          $this->semValue = true; 
1314 |     }
1315 | 
1316 |     protected function reduceRule72($attributes) {
1317 |          $this->semValue = new Node\Stmt\Function_($this->semStack[$this->stackPos-(11-3)], array('byRef' => $this->semStack[$this->stackPos-(11-2)], 'params' => $this->semStack[$this->stackPos-(11-6)], 'returnType' => $this->semStack[$this->stackPos-(11-8)], 'stmts' => $this->semStack[$this->stackPos-(11-10)]), array('generics' => $this->semStack[$this->stackPos-(11-4)]), $attributes); 
1318 |     }
1319 | 
1320 |     protected function reduceRule73($attributes) {
1321 |          $this->semValue = new Node\Stmt\Class_($this->semStack[$this->stackPos-(8-2)], array('type' => $this->semStack[$this->stackPos-(8-1)], 'extends' => $this->semStack[$this->stackPos-(8-4)], 'implements' => $this->semStack[$this->stackPos-(8-5)], 'stmts' => $this->semStack[$this->stackPos-(8-7)]), array('generics' => $this->semStack[$this->stackPos-(8-3)]), $attributes); 
1322 |     }
1323 | 
1324 |     protected function reduceRule74($attributes) {
1325 |          $this->semValue = new Node\Stmt\Interface_($this->semStack[$this->stackPos-(7-2)], array('extends' => $this->semStack[$this->stackPos-(7-4)], 'stmts' => $this->semStack[$this->stackPos-(7-6)]), array('generics' => $this->semStack[$this->stackPos-(7-3)]), $attributes); 
1326 |     }
1327 | 
1328 |     protected function reduceRule75($attributes) {
1329 |          $this->semValue = new Node\Stmt\Trait_($this->semStack[$this->stackPos-(6-2)], $this->semStack[$this->stackPos-(6-5)], array('generics' => $this->semStack[$this->stackPos-(6-3)]), $attributes); 
1330 |     }
1331 | 
1332 |     protected function reduceRule76($attributes) {
1333 |          $this->semValue = null; 
1334 |     }
1335 | 
1336 |     protected function reduceRule77($attributes) {
1337 |          $this->semValue = null; 
1338 |     }
1339 | 
1340 |     protected function reduceRule78($attributes) {
1341 |          $this->semValue = $this->semStack[$this->stackPos-(3-2)]; 
1342 |     }
1343 | 
1344 |     protected function reduceRule79($attributes) {
1345 |          $this->semValue = array($this->semStack[$this->stackPos-(1-1)]); 
1346 |     }
1347 | 
1348 |     protected function reduceRule80($attributes) {
1349 |          $this->semStack[$this->stackPos-(3-1)][] = $this->semStack[$this->stackPos-(3-3)]; $this->semValue = $this->semStack[$this->stackPos-(3-1)]; 
1350 |     }
1351 | 
1352 |     protected function reduceRule81($attributes) {
1353 |          $this->semValue = 0; 
1354 |     }
1355 | 
1356 |     protected function reduceRule82($attributes) {
1357 |          $this->semValue = Node\Stmt\Class_::MODIFIER_ABSTRACT; 
1358 |     }
1359 | 
1360 |     protected function reduceRule83($attributes) {
1361 |          $this->semValue = Node\Stmt\Class_::MODIFIER_FINAL; 
1362 |     }
1363 | 
1364 |     protected function reduceRule84($attributes) {
1365 |          $this->semValue = null; 
1366 |     }
1367 | 
1368 |     protected function reduceRule85($attributes) {
1369 |          $this->semValue = $this->semStack[$this->stackPos-(2-2)]; 
1370 |     }
1371 | 
1372 |     protected function reduceRule86($attributes) {
1373 |          $this->semValue = array(); 
1374 |     }
1375 | 
1376 |     protected function reduceRule87($attributes) {
1377 |          $this->semValue = $this->semStack[$this->stackPos-(2-2)]; 
1378 |     }
1379 | 
1380 |     protected function reduceRule88($attributes) {
1381 |          $this->semValue = array(); 
1382 |     }
1383 | 
1384 |     protected function reduceRule89($attributes) {
1385 |          $this->semValue = $this->semStack[$this->stackPos-(2-2)]; 
1386 |     }
1387 | 
1388 |     protected function reduceRule90($attributes) {
1389 |          $this->semValue = array($this->semStack[$this->stackPos-(1-1)]); 
1390 |     }
1391 | 
1392 |     protected function reduceRule91($attributes) {
1393 |          $this->semStack[$this->stackPos-(3-1)][] = $this->semStack[$this->stackPos-(3-3)]; $this->semValue = $this->semStack[$this->stackPos-(3-1)]; 
1394 |     }
1395 | 
1396 |     protected function reduceRule92($attributes) {
1397 |          $this->semValue = is_array($this->semStack[$this->stackPos-(1-1)]) ? $this->semStack[$this->stackPos-(1-1)] : array($this->semStack[$this->stackPos-(1-1)]); 
1398 |     }
1399 | 
1400 |     protected function reduceRule93($attributes) {
1401 |          $this->semValue = $this->semStack[$this->stackPos-(4-2)]; 
1402 |     }
1403 | 
1404 |     protected function reduceRule94($attributes) {
1405 |          $this->semValue = is_array($this->semStack[$this->stackPos-(1-1)]) ? $this->semStack[$this->stackPos-(1-1)] : array($this->semStack[$this->stackPos-(1-1)]); 
1406 |     }
1407 | 
1408 |     protected function reduceRule95($attributes) {
1409 |          $this->semValue = $this->semStack[$this->stackPos-(4-2)]; 
1410 |     }
1411 | 
1412 |     protected function reduceRule96($attributes) {
1413 |          $this->semValue = is_array($this->semStack[$this->stackPos-(1-1)]) ? $this->semStack[$this->stackPos-(1-1)] : array($this->semStack[$this->stackPos-(1-1)]); 
1414 |     }
1415 | 
1416 |     protected function reduceRule97($attributes) {
1417 |          $this->semValue = $this->semStack[$this->stackPos-(4-2)]; 
1418 |     }
1419 | 
1420 |     protected function reduceRule98($attributes) {
1421 |          $this->semValue = array($this->semStack[$this->stackPos-(1-1)]); 
1422 |     }
1423 | 
1424 |     protected function reduceRule99($attributes) {
1425 |          $this->semStack[$this->stackPos-(3-1)][] = $this->semStack[$this->stackPos-(3-3)]; $this->semValue = $this->semStack[$this->stackPos-(3-1)]; 
1426 |     }
1427 | 
1428 |     protected function reduceRule100($attributes) {
1429 |          $this->semValue = new Node\Stmt\DeclareDeclare($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1430 |     }
1431 | 
1432 |     protected function reduceRule101($attributes) {
1433 |          $this->semValue = $this->semStack[$this->stackPos-(3-2)]; 
1434 |     }
1435 | 
1436 |     protected function reduceRule102($attributes) {
1437 |          $this->semValue = $this->semStack[$this->stackPos-(4-3)]; 
1438 |     }
1439 | 
1440 |     protected function reduceRule103($attributes) {
1441 |          $this->semValue = $this->semStack[$this->stackPos-(4-2)]; 
1442 |     }
1443 | 
1444 |     protected function reduceRule104($attributes) {
1445 |          $this->semValue = $this->semStack[$this->stackPos-(5-3)]; 
1446 |     }
1447 | 
1448 |     protected function reduceRule105($attributes) {
1449 |          $this->semValue = array(); 
1450 |     }
1451 | 
1452 |     protected function reduceRule106($attributes) {
1453 |          $this->semStack[$this->stackPos-(2-1)][] = $this->semStack[$this->stackPos-(2-2)]; $this->semValue = $this->semStack[$this->stackPos-(2-1)]; 
1454 |     }
1455 | 
1456 |     protected function reduceRule107($attributes) {
1457 |          $this->semValue = new Node\Stmt\Case_($this->semStack[$this->stackPos-(4-2)], $this->semStack[$this->stackPos-(4-4)], $attributes); 
1458 |     }
1459 | 
1460 |     protected function reduceRule108($attributes) {
1461 |          $this->semValue = new Node\Stmt\Case_(null, $this->semStack[$this->stackPos-(3-3)], $attributes); 
1462 |     }
1463 | 
1464 |     protected function reduceRule109() {
1465 |         $this->semValue = $this->semStack[$this->stackPos];
1466 |     }
1467 | 
1468 |     protected function reduceRule110() {
1469 |         $this->semValue = $this->semStack[$this->stackPos];
1470 |     }
1471 | 
1472 |     protected function reduceRule111($attributes) {
1473 |          $this->semValue = is_array($this->semStack[$this->stackPos-(1-1)]) ? $this->semStack[$this->stackPos-(1-1)] : array($this->semStack[$this->stackPos-(1-1)]); 
1474 |     }
1475 | 
1476 |     protected function reduceRule112($attributes) {
1477 |          $this->semValue = $this->semStack[$this->stackPos-(4-2)]; 
1478 |     }
1479 | 
1480 |     protected function reduceRule113($attributes) {
1481 |          $this->semValue = array(); 
1482 |     }
1483 | 
1484 |     protected function reduceRule114($attributes) {
1485 |          $this->semStack[$this->stackPos-(2-1)][] = $this->semStack[$this->stackPos-(2-2)]; $this->semValue = $this->semStack[$this->stackPos-(2-1)]; 
1486 |     }
1487 | 
1488 |     protected function reduceRule115($attributes) {
1489 |          $this->semValue = new Node\Stmt\ElseIf_($this->semStack[$this->stackPos-(3-2)], is_array($this->semStack[$this->stackPos-(3-3)]) ? $this->semStack[$this->stackPos-(3-3)] : array($this->semStack[$this->stackPos-(3-3)]), $attributes); 
1490 |     }
1491 | 
1492 |     protected function reduceRule116($attributes) {
1493 |          $this->semValue = array(); 
1494 |     }
1495 | 
1496 |     protected function reduceRule117($attributes) {
1497 |          $this->semStack[$this->stackPos-(2-1)][] = $this->semStack[$this->stackPos-(2-2)]; $this->semValue = $this->semStack[$this->stackPos-(2-1)]; 
1498 |     }
1499 | 
1500 |     protected function reduceRule118($attributes) {
1501 |          $this->semValue = new Node\Stmt\ElseIf_($this->semStack[$this->stackPos-(4-2)], $this->semStack[$this->stackPos-(4-4)], $attributes); 
1502 |     }
1503 | 
1504 |     protected function reduceRule119($attributes) {
1505 |          $this->semValue = null; 
1506 |     }
1507 | 
1508 |     protected function reduceRule120($attributes) {
1509 |          $this->semValue = new Node\Stmt\Else_(is_array($this->semStack[$this->stackPos-(2-2)]) ? $this->semStack[$this->stackPos-(2-2)] : array($this->semStack[$this->stackPos-(2-2)]), $attributes); 
1510 |     }
1511 | 
1512 |     protected function reduceRule121($attributes) {
1513 |          $this->semValue = null; 
1514 |     }
1515 | 
1516 |     protected function reduceRule122($attributes) {
1517 |          $this->semValue = new Node\Stmt\Else_($this->semStack[$this->stackPos-(3-3)], $attributes); 
1518 |     }
1519 | 
1520 |     protected function reduceRule123($attributes) {
1521 |          $this->semValue = array($this->semStack[$this->stackPos-(1-1)], false); 
1522 |     }
1523 | 
1524 |     protected function reduceRule124($attributes) {
1525 |          $this->semValue = array($this->semStack[$this->stackPos-(2-2)], true); 
1526 |     }
1527 | 
1528 |     protected function reduceRule125($attributes) {
1529 |          $this->semValue = array($this->semStack[$this->stackPos-(1-1)], false); 
1530 |     }
1531 | 
1532 |     protected function reduceRule126($attributes) {
1533 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
1534 |     }
1535 | 
1536 |     protected function reduceRule127($attributes) {
1537 |          $this->semValue = array(); 
1538 |     }
1539 | 
1540 |     protected function reduceRule128($attributes) {
1541 |          $this->semValue = array($this->semStack[$this->stackPos-(1-1)]); 
1542 |     }
1543 | 
1544 |     protected function reduceRule129($attributes) {
1545 |          $this->semStack[$this->stackPos-(3-1)][] = $this->semStack[$this->stackPos-(3-3)]; $this->semValue = $this->semStack[$this->stackPos-(3-1)]; 
1546 |     }
1547 | 
1548 |     protected function reduceRule130($attributes) {
1549 |          $this->semValue = new Node\Param(substr($this->semStack[$this->stackPos-(4-4)], 1), null, $this->semStack[$this->stackPos-(4-1)], $this->semStack[$this->stackPos-(4-2)], $this->semStack[$this->stackPos-(4-3)], $attributes); 
1550 |     }
1551 | 
1552 |     protected function reduceRule131($attributes) {
1553 |          $this->semValue = new Node\Param(substr($this->semStack[$this->stackPos-(6-4)], 1), $this->semStack[$this->stackPos-(6-6)], $this->semStack[$this->stackPos-(6-1)], $this->semStack[$this->stackPos-(6-2)], $this->semStack[$this->stackPos-(6-3)], $attributes); 
1554 |     }
1555 | 
1556 |     protected function reduceRule132($attributes) {
1557 |          $this->semValue = $this->semStack[$this->stackPos-(2-1)]; $this->semStack[$this->stackPos-(2-1)]->setAttribute("generics", $this->semStack[$this->stackPos-(2-2)]); 
1558 |     }
1559 | 
1560 |     protected function reduceRule133($attributes) {
1561 |          $this->semValue = 'array'; 
1562 |     }
1563 | 
1564 |     protected function reduceRule134($attributes) {
1565 |          $this->semValue = 'callable'; 
1566 |     }
1567 | 
1568 |     protected function reduceRule135($attributes) {
1569 |          $this->semValue = null; 
1570 |     }
1571 | 
1572 |     protected function reduceRule136($attributes) {
1573 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
1574 |     }
1575 | 
1576 |     protected function reduceRule137($attributes) {
1577 |          $this->semValue = null; 
1578 |     }
1579 | 
1580 |     protected function reduceRule138($attributes) {
1581 |          $this->semValue = $this->semStack[$this->stackPos-(2-2)]; 
1582 |     }
1583 | 
1584 |     protected function reduceRule139($attributes) {
1585 |          $this->semValue = array(); 
1586 |     }
1587 | 
1588 |     protected function reduceRule140($attributes) {
1589 |          $this->semValue = $this->semStack[$this->stackPos-(3-2)]; 
1590 |     }
1591 | 
1592 |     protected function reduceRule141($attributes) {
1593 |          $this->semValue = array(new Node\Arg($this->semStack[$this->stackPos-(3-2)], false, false, $attributes)); 
1594 |     }
1595 | 
1596 |     protected function reduceRule142($attributes) {
1597 |          $this->semValue = array($this->semStack[$this->stackPos-(1-1)]); 
1598 |     }
1599 | 
1600 |     protected function reduceRule143($attributes) {
1601 |          $this->semStack[$this->stackPos-(3-1)][] = $this->semStack[$this->stackPos-(3-3)]; $this->semValue = $this->semStack[$this->stackPos-(3-1)]; 
1602 |     }
1603 | 
1604 |     protected function reduceRule144($attributes) {
1605 |          $this->semValue = new Node\Arg($this->semStack[$this->stackPos-(1-1)], false, false, $attributes); 
1606 |     }
1607 | 
1608 |     protected function reduceRule145($attributes) {
1609 |          $this->semValue = new Node\Arg($this->semStack[$this->stackPos-(2-2)], true, false, $attributes); 
1610 |     }
1611 | 
1612 |     protected function reduceRule146($attributes) {
1613 |          $this->semValue = new Node\Arg($this->semStack[$this->stackPos-(2-2)], false, true, $attributes); 
1614 |     }
1615 | 
1616 |     protected function reduceRule147($attributes) {
1617 |          $this->semStack[$this->stackPos-(3-1)][] = $this->semStack[$this->stackPos-(3-3)]; $this->semValue = $this->semStack[$this->stackPos-(3-1)]; 
1618 |     }
1619 | 
1620 |     protected function reduceRule148($attributes) {
1621 |          $this->semValue = array($this->semStack[$this->stackPos-(1-1)]); 
1622 |     }
1623 | 
1624 |     protected function reduceRule149($attributes) {
1625 |          $this->semValue = new Node\Expr\Variable(substr($this->semStack[$this->stackPos-(1-1)], 1), $attributes); 
1626 |     }
1627 | 
1628 |     protected function reduceRule150($attributes) {
1629 |          $this->semValue = new Node\Expr\Variable($this->semStack[$this->stackPos-(2-2)], $attributes); 
1630 |     }
1631 | 
1632 |     protected function reduceRule151($attributes) {
1633 |          $this->semValue = new Node\Expr\Variable($this->semStack[$this->stackPos-(4-3)], $attributes); 
1634 |     }
1635 | 
1636 |     protected function reduceRule152($attributes) {
1637 |          $this->semStack[$this->stackPos-(3-1)][] = $this->semStack[$this->stackPos-(3-3)]; $this->semValue = $this->semStack[$this->stackPos-(3-1)]; 
1638 |     }
1639 | 
1640 |     protected function reduceRule153($attributes) {
1641 |          $this->semValue = array($this->semStack[$this->stackPos-(1-1)]); 
1642 |     }
1643 | 
1644 |     protected function reduceRule154($attributes) {
1645 |          $this->semValue = new Node\Stmt\StaticVar(substr($this->semStack[$this->stackPos-(1-1)], 1), null, $attributes); 
1646 |     }
1647 | 
1648 |     protected function reduceRule155($attributes) {
1649 |          $this->semValue = new Node\Stmt\StaticVar(substr($this->semStack[$this->stackPos-(3-1)], 1), $this->semStack[$this->stackPos-(3-3)], $attributes); 
1650 |     }
1651 | 
1652 |     protected function reduceRule156($attributes) {
1653 |          $this->semStack[$this->stackPos-(2-1)][] = $this->semStack[$this->stackPos-(2-2)]; $this->semValue = $this->semStack[$this->stackPos-(2-1)]; 
1654 |     }
1655 | 
1656 |     protected function reduceRule157($attributes) {
1657 |          $this->semValue = array(); 
1658 |     }
1659 | 
1660 |     protected function reduceRule158($attributes) {
1661 |          $this->semValue = new Node\Stmt\Property($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-2)], $attributes); 
1662 |     }
1663 | 
1664 |     protected function reduceRule159($attributes) {
1665 |          $this->semValue = new Node\Stmt\ClassConst($this->semStack[$this->stackPos-(3-2)], $attributes); 
1666 |     }
1667 | 
1668 |     protected function reduceRule160($attributes) {
1669 |          $this->semValue = new Node\Stmt\ClassMethod($this->semStack[$this->stackPos-(10-4)], array('type' => $this->semStack[$this->stackPos-(10-1)], 'byRef' => $this->semStack[$this->stackPos-(10-3)], 'params' => $this->semStack[$this->stackPos-(10-7)], 'returnType' => $this->semStack[$this->stackPos-(10-9)], 'stmts' => $this->semStack[$this->stackPos-(10-10)]), array('generics' => $this->semStack[$this->stackPos-(10-5)]), $attributes); 
1670 |     }
1671 | 
1672 |     protected function reduceRule161($attributes) {
1673 |          $this->semValue = new Node\Stmt\TraitUse($this->semStack[$this->stackPos-(3-2)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1674 |     }
1675 | 
1676 |     protected function reduceRule162($attributes) {
1677 |          $this->semValue = array(); 
1678 |     }
1679 | 
1680 |     protected function reduceRule163($attributes) {
1681 |          $this->semValue = $this->semStack[$this->stackPos-(3-2)]; 
1682 |     }
1683 | 
1684 |     protected function reduceRule164($attributes) {
1685 |          $this->semValue = array(); 
1686 |     }
1687 | 
1688 |     protected function reduceRule165($attributes) {
1689 |          $this->semStack[$this->stackPos-(2-1)][] = $this->semStack[$this->stackPos-(2-2)]; $this->semValue = $this->semStack[$this->stackPos-(2-1)]; 
1690 |     }
1691 | 
1692 |     protected function reduceRule166($attributes) {
1693 |          $this->semValue = new Node\Stmt\TraitUseAdaptation\Precedence($this->semStack[$this->stackPos-(4-1)][0], $this->semStack[$this->stackPos-(4-1)][1], $this->semStack[$this->stackPos-(4-3)], $attributes); 
1694 |     }
1695 | 
1696 |     protected function reduceRule167($attributes) {
1697 |          $this->semValue = new Node\Stmt\TraitUseAdaptation\Alias($this->semStack[$this->stackPos-(5-1)][0], $this->semStack[$this->stackPos-(5-1)][1], $this->semStack[$this->stackPos-(5-3)], $this->semStack[$this->stackPos-(5-4)], $attributes); 
1698 |     }
1699 | 
1700 |     protected function reduceRule168($attributes) {
1701 |          $this->semValue = new Node\Stmt\TraitUseAdaptation\Alias($this->semStack[$this->stackPos-(4-1)][0], $this->semStack[$this->stackPos-(4-1)][1], $this->semStack[$this->stackPos-(4-3)], null, $attributes); 
1702 |     }
1703 | 
1704 |     protected function reduceRule169($attributes) {
1705 |          $this->semValue = new Node\Stmt\TraitUseAdaptation\Alias($this->semStack[$this->stackPos-(4-1)][0], $this->semStack[$this->stackPos-(4-1)][1], null, $this->semStack[$this->stackPos-(4-3)], $attributes); 
1706 |     }
1707 | 
1708 |     protected function reduceRule170($attributes) {
1709 |          $this->semValue = array($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)]); 
1710 |     }
1711 | 
1712 |     protected function reduceRule171($attributes) {
1713 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
1714 |     }
1715 | 
1716 |     protected function reduceRule172($attributes) {
1717 |          $this->semValue = array(null, $this->semStack[$this->stackPos-(1-1)]); 
1718 |     }
1719 | 
1720 |     protected function reduceRule173($attributes) {
1721 |          $this->semValue = null; 
1722 |     }
1723 | 
1724 |     protected function reduceRule174($attributes) {
1725 |          $this->semValue = $this->semStack[$this->stackPos-(3-2)]; 
1726 |     }
1727 | 
1728 |     protected function reduceRule175($attributes) {
1729 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
1730 |     }
1731 | 
1732 |     protected function reduceRule176($attributes) {
1733 |          $this->semValue = 0; 
1734 |     }
1735 | 
1736 |     protected function reduceRule177($attributes) {
1737 |          $this->semValue = 0; 
1738 |     }
1739 | 
1740 |     protected function reduceRule178($attributes) {
1741 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
1742 |     }
1743 | 
1744 |     protected function reduceRule179($attributes) {
1745 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
1746 |     }
1747 | 
1748 |     protected function reduceRule180($attributes) {
1749 |          Node\Stmt\Class_::verifyModifier($this->semStack[$this->stackPos-(2-1)], $this->semStack[$this->stackPos-(2-2)]); $this->semValue = $this->semStack[$this->stackPos-(2-1)] | $this->semStack[$this->stackPos-(2-2)]; 
1750 |     }
1751 | 
1752 |     protected function reduceRule181($attributes) {
1753 |          $this->semValue = Node\Stmt\Class_::MODIFIER_PUBLIC; 
1754 |     }
1755 | 
1756 |     protected function reduceRule182($attributes) {
1757 |          $this->semValue = Node\Stmt\Class_::MODIFIER_PROTECTED; 
1758 |     }
1759 | 
1760 |     protected function reduceRule183($attributes) {
1761 |          $this->semValue = Node\Stmt\Class_::MODIFIER_PRIVATE; 
1762 |     }
1763 | 
1764 |     protected function reduceRule184($attributes) {
1765 |          $this->semValue = Node\Stmt\Class_::MODIFIER_STATIC; 
1766 |     }
1767 | 
1768 |     protected function reduceRule185($attributes) {
1769 |          $this->semValue = Node\Stmt\Class_::MODIFIER_ABSTRACT; 
1770 |     }
1771 | 
1772 |     protected function reduceRule186($attributes) {
1773 |          $this->semValue = Node\Stmt\Class_::MODIFIER_FINAL; 
1774 |     }
1775 | 
1776 |     protected function reduceRule187($attributes) {
1777 |          $this->semValue = array($this->semStack[$this->stackPos-(1-1)]); 
1778 |     }
1779 | 
1780 |     protected function reduceRule188($attributes) {
1781 |          $this->semStack[$this->stackPos-(3-1)][] = $this->semStack[$this->stackPos-(3-3)]; $this->semValue = $this->semStack[$this->stackPos-(3-1)]; 
1782 |     }
1783 | 
1784 |     protected function reduceRule189($attributes) {
1785 |          $this->semValue = new Node\Stmt\PropertyProperty(substr($this->semStack[$this->stackPos-(1-1)], 1), null, $attributes); 
1786 |     }
1787 | 
1788 |     protected function reduceRule190($attributes) {
1789 |          $this->semValue = new Node\Stmt\PropertyProperty(substr($this->semStack[$this->stackPos-(3-1)], 1), $this->semStack[$this->stackPos-(3-3)], $attributes); 
1790 |     }
1791 | 
1792 |     protected function reduceRule191($attributes) {
1793 |          $this->semStack[$this->stackPos-(3-1)][] = $this->semStack[$this->stackPos-(3-3)]; $this->semValue = $this->semStack[$this->stackPos-(3-1)]; 
1794 |     }
1795 | 
1796 |     protected function reduceRule192($attributes) {
1797 |          $this->semValue = array($this->semStack[$this->stackPos-(1-1)]); 
1798 |     }
1799 | 
1800 |     protected function reduceRule193($attributes) {
1801 |          $this->semValue = array(); 
1802 |     }
1803 | 
1804 |     protected function reduceRule194($attributes) {
1805 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
1806 |     }
1807 | 
1808 |     protected function reduceRule195($attributes) {
1809 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
1810 |     }
1811 | 
1812 |     protected function reduceRule196($attributes) {
1813 |          $this->semValue = new Node\Expr\Assign($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1814 |     }
1815 | 
1816 |     protected function reduceRule197($attributes) {
1817 |          $this->semValue = new Node\Expr\Assign($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1818 |     }
1819 | 
1820 |     protected function reduceRule198($attributes) {
1821 |          $this->semValue = new Node\Expr\AssignRef($this->semStack[$this->stackPos-(4-1)], $this->semStack[$this->stackPos-(4-4)], $attributes); 
1822 |     }
1823 | 
1824 |     protected function reduceRule199($attributes) {
1825 |          $this->semValue = new Node\Expr\AssignRef($this->semStack[$this->stackPos-(4-1)], $this->semStack[$this->stackPos-(4-4)], $attributes); 
1826 |     }
1827 | 
1828 |     protected function reduceRule200($attributes) {
1829 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
1830 |     }
1831 | 
1832 |     protected function reduceRule201($attributes) {
1833 |          $this->semValue = new Node\Expr\Clone_($this->semStack[$this->stackPos-(2-2)], $attributes); 
1834 |     }
1835 | 
1836 |     protected function reduceRule202($attributes) {
1837 |          $this->semValue = new Node\Expr\AssignOp\Plus($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1838 |     }
1839 | 
1840 |     protected function reduceRule203($attributes) {
1841 |          $this->semValue = new Node\Expr\AssignOp\Minus($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1842 |     }
1843 | 
1844 |     protected function reduceRule204($attributes) {
1845 |          $this->semValue = new Node\Expr\AssignOp\Mul($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1846 |     }
1847 | 
1848 |     protected function reduceRule205($attributes) {
1849 |          $this->semValue = new Node\Expr\AssignOp\Div($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1850 |     }
1851 | 
1852 |     protected function reduceRule206($attributes) {
1853 |          $this->semValue = new Node\Expr\AssignOp\Concat($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1854 |     }
1855 | 
1856 |     protected function reduceRule207($attributes) {
1857 |          $this->semValue = new Node\Expr\AssignOp\Mod($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1858 |     }
1859 | 
1860 |     protected function reduceRule208($attributes) {
1861 |          $this->semValue = new Node\Expr\AssignOp\BitwiseAnd($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1862 |     }
1863 | 
1864 |     protected function reduceRule209($attributes) {
1865 |          $this->semValue = new Node\Expr\AssignOp\BitwiseOr($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1866 |     }
1867 | 
1868 |     protected function reduceRule210($attributes) {
1869 |          $this->semValue = new Node\Expr\AssignOp\BitwiseXor($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1870 |     }
1871 | 
1872 |     protected function reduceRule211($attributes) {
1873 |          $this->semValue = new Node\Expr\AssignOp\ShiftLeft($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1874 |     }
1875 | 
1876 |     protected function reduceRule212($attributes) {
1877 |          $this->semValue = new Node\Expr\AssignOp\ShiftRight($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1878 |     }
1879 | 
1880 |     protected function reduceRule213($attributes) {
1881 |          $this->semValue = new Node\Expr\AssignOp\Pow($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1882 |     }
1883 | 
1884 |     protected function reduceRule214($attributes) {
1885 |          $this->semValue = new Node\Expr\PostInc($this->semStack[$this->stackPos-(2-1)], $attributes); 
1886 |     }
1887 | 
1888 |     protected function reduceRule215($attributes) {
1889 |          $this->semValue = new Node\Expr\PreInc($this->semStack[$this->stackPos-(2-2)], $attributes); 
1890 |     }
1891 | 
1892 |     protected function reduceRule216($attributes) {
1893 |          $this->semValue = new Node\Expr\PostDec($this->semStack[$this->stackPos-(2-1)], $attributes); 
1894 |     }
1895 | 
1896 |     protected function reduceRule217($attributes) {
1897 |          $this->semValue = new Node\Expr\PreDec($this->semStack[$this->stackPos-(2-2)], $attributes); 
1898 |     }
1899 | 
1900 |     protected function reduceRule218($attributes) {
1901 |          $this->semValue = new Node\Expr\BinaryOp\BooleanOr($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1902 |     }
1903 | 
1904 |     protected function reduceRule219($attributes) {
1905 |          $this->semValue = new Node\Expr\BinaryOp\BooleanAnd($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1906 |     }
1907 | 
1908 |     protected function reduceRule220($attributes) {
1909 |          $this->semValue = new Node\Expr\BinaryOp\LogicalOr($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1910 |     }
1911 | 
1912 |     protected function reduceRule221($attributes) {
1913 |          $this->semValue = new Node\Expr\BinaryOp\LogicalAnd($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1914 |     }
1915 | 
1916 |     protected function reduceRule222($attributes) {
1917 |          $this->semValue = new Node\Expr\BinaryOp\LogicalXor($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1918 |     }
1919 | 
1920 |     protected function reduceRule223($attributes) {
1921 |          $this->semValue = new Node\Expr\BinaryOp\BitwiseOr($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1922 |     }
1923 | 
1924 |     protected function reduceRule224($attributes) {
1925 |          $this->semValue = new Node\Expr\BinaryOp\BitwiseAnd($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1926 |     }
1927 | 
1928 |     protected function reduceRule225($attributes) {
1929 |          $this->semValue = new Node\Expr\BinaryOp\BitwiseXor($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1930 |     }
1931 | 
1932 |     protected function reduceRule226($attributes) {
1933 |          $this->semValue = new Node\Expr\BinaryOp\Concat($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1934 |     }
1935 | 
1936 |     protected function reduceRule227($attributes) {
1937 |          $this->semValue = new Node\Expr\BinaryOp\Plus($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1938 |     }
1939 | 
1940 |     protected function reduceRule228($attributes) {
1941 |          $this->semValue = new Node\Expr\BinaryOp\Minus($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1942 |     }
1943 | 
1944 |     protected function reduceRule229($attributes) {
1945 |          $this->semValue = new Node\Expr\BinaryOp\Mul($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1946 |     }
1947 | 
1948 |     protected function reduceRule230($attributes) {
1949 |          $this->semValue = new Node\Expr\BinaryOp\Div($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1950 |     }
1951 | 
1952 |     protected function reduceRule231($attributes) {
1953 |          $this->semValue = new Node\Expr\BinaryOp\Mod($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1954 |     }
1955 | 
1956 |     protected function reduceRule232($attributes) {
1957 |          $this->semValue = new Node\Expr\BinaryOp\ShiftLeft($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1958 |     }
1959 | 
1960 |     protected function reduceRule233($attributes) {
1961 |          $this->semValue = new Node\Expr\BinaryOp\ShiftRight($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1962 |     }
1963 | 
1964 |     protected function reduceRule234($attributes) {
1965 |          $this->semValue = new Node\Expr\BinaryOp\Pow($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1966 |     }
1967 | 
1968 |     protected function reduceRule235($attributes) {
1969 |          $this->semValue = new Node\Expr\UnaryPlus($this->semStack[$this->stackPos-(2-2)], $attributes); 
1970 |     }
1971 | 
1972 |     protected function reduceRule236($attributes) {
1973 |          $this->semValue = new Node\Expr\UnaryMinus($this->semStack[$this->stackPos-(2-2)], $attributes); 
1974 |     }
1975 | 
1976 |     protected function reduceRule237($attributes) {
1977 |          $this->semValue = new Node\Expr\BooleanNot($this->semStack[$this->stackPos-(2-2)], $attributes); 
1978 |     }
1979 | 
1980 |     protected function reduceRule238($attributes) {
1981 |          $this->semValue = new Node\Expr\BitwiseNot($this->semStack[$this->stackPos-(2-2)], $attributes); 
1982 |     }
1983 | 
1984 |     protected function reduceRule239($attributes) {
1985 |          $this->semValue = new Node\Expr\BinaryOp\Identical($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1986 |     }
1987 | 
1988 |     protected function reduceRule240($attributes) {
1989 |          $this->semValue = new Node\Expr\BinaryOp\NotIdentical($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1990 |     }
1991 | 
1992 |     protected function reduceRule241($attributes) {
1993 |          $this->semValue = new Node\Expr\BinaryOp\Equal($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1994 |     }
1995 | 
1996 |     protected function reduceRule242($attributes) {
1997 |          $this->semValue = new Node\Expr\BinaryOp\NotEqual($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
1998 |     }
1999 | 
2000 |     protected function reduceRule243($attributes) {
2001 |          $this->semValue = new Node\Expr\BinaryOp\Spaceship($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2002 |     }
2003 | 
2004 |     protected function reduceRule244($attributes) {
2005 |          $this->semValue = new Node\Expr\BinaryOp\Smaller($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2006 |     }
2007 | 
2008 |     protected function reduceRule245($attributes) {
2009 |          $this->semValue = new Node\Expr\BinaryOp\SmallerOrEqual($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2010 |     }
2011 | 
2012 |     protected function reduceRule246($attributes) {
2013 |          $this->semValue = new Node\Expr\BinaryOp\Greater($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2014 |     }
2015 | 
2016 |     protected function reduceRule247($attributes) {
2017 |          $this->semValue = new Node\Expr\BinaryOp\GreaterOrEqual($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2018 |     }
2019 | 
2020 |     protected function reduceRule248($attributes) {
2021 |          $this->semValue = new Node\Expr\Instanceof_($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2022 |     }
2023 | 
2024 |     protected function reduceRule249($attributes) {
2025 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2026 |     }
2027 | 
2028 |     protected function reduceRule250($attributes) {
2029 |          $this->semValue = $this->semStack[$this->stackPos-(3-2)]; 
2030 |     }
2031 | 
2032 |     protected function reduceRule251($attributes) {
2033 |          $this->semValue = new Node\Expr\Ternary($this->semStack[$this->stackPos-(5-1)], $this->semStack[$this->stackPos-(5-3)], $this->semStack[$this->stackPos-(5-5)], $attributes); 
2034 |     }
2035 | 
2036 |     protected function reduceRule252($attributes) {
2037 |          $this->semValue = new Node\Expr\Ternary($this->semStack[$this->stackPos-(4-1)], null, $this->semStack[$this->stackPos-(4-4)], $attributes); 
2038 |     }
2039 | 
2040 |     protected function reduceRule253($attributes) {
2041 |          $this->semValue = new Node\Expr\BinaryOp\Coalesce($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2042 |     }
2043 | 
2044 |     protected function reduceRule254($attributes) {
2045 |          $this->semValue = new Node\Expr\Isset_($this->semStack[$this->stackPos-(4-3)], $attributes); 
2046 |     }
2047 | 
2048 |     protected function reduceRule255($attributes) {
2049 |          $this->semValue = new Node\Expr\Empty_($this->semStack[$this->stackPos-(4-3)], $attributes); 
2050 |     }
2051 | 
2052 |     protected function reduceRule256($attributes) {
2053 |          $this->semValue = new Node\Expr\Include_($this->semStack[$this->stackPos-(2-2)], Node\Expr\Include_::TYPE_INCLUDE, $attributes); 
2054 |     }
2055 | 
2056 |     protected function reduceRule257($attributes) {
2057 |          $this->semValue = new Node\Expr\Include_($this->semStack[$this->stackPos-(2-2)], Node\Expr\Include_::TYPE_INCLUDE_ONCE, $attributes); 
2058 |     }
2059 | 
2060 |     protected function reduceRule258($attributes) {
2061 |          $this->semValue = new Node\Expr\Eval_($this->semStack[$this->stackPos-(2-2)], $attributes); 
2062 |     }
2063 | 
2064 |     protected function reduceRule259($attributes) {
2065 |          $this->semValue = new Node\Expr\Include_($this->semStack[$this->stackPos-(2-2)], Node\Expr\Include_::TYPE_REQUIRE, $attributes); 
2066 |     }
2067 | 
2068 |     protected function reduceRule260($attributes) {
2069 |          $this->semValue = new Node\Expr\Include_($this->semStack[$this->stackPos-(2-2)], Node\Expr\Include_::TYPE_REQUIRE_ONCE, $attributes); 
2070 |     }
2071 | 
2072 |     protected function reduceRule261($attributes) {
2073 |          $this->semValue = new Node\Expr\Cast\Int_($this->semStack[$this->stackPos-(2-2)], $attributes); 
2074 |     }
2075 | 
2076 |     protected function reduceRule262($attributes) {
2077 |          $this->semValue = new Node\Expr\Cast\Double($this->semStack[$this->stackPos-(2-2)], $attributes); 
2078 |     }
2079 | 
2080 |     protected function reduceRule263($attributes) {
2081 |          $this->semValue = new Node\Expr\Cast\String_($this->semStack[$this->stackPos-(2-2)], $attributes); 
2082 |     }
2083 | 
2084 |     protected function reduceRule264($attributes) {
2085 |          $this->semValue = new Node\Expr\Cast\Array_($this->semStack[$this->stackPos-(2-2)], $attributes); 
2086 |     }
2087 | 
2088 |     protected function reduceRule265($attributes) {
2089 |          $this->semValue = new Node\Expr\Cast\Object_($this->semStack[$this->stackPos-(2-2)], $attributes); 
2090 |     }
2091 | 
2092 |     protected function reduceRule266($attributes) {
2093 |          $this->semValue = new Node\Expr\Cast\Bool_($this->semStack[$this->stackPos-(2-2)], $attributes); 
2094 |     }
2095 | 
2096 |     protected function reduceRule267($attributes) {
2097 |          $this->semValue = new Node\Expr\Cast\Unset_($this->semStack[$this->stackPos-(2-2)], $attributes); 
2098 |     }
2099 | 
2100 |     protected function reduceRule268($attributes) {
2101 |          $this->semValue = new Node\Expr\Exit_($this->semStack[$this->stackPos-(2-2)], $attributes); 
2102 |     }
2103 | 
2104 |     protected function reduceRule269($attributes) {
2105 |          $this->semValue = new Node\Expr\ErrorSuppress($this->semStack[$this->stackPos-(2-2)], $attributes); 
2106 |     }
2107 | 
2108 |     protected function reduceRule270($attributes) {
2109 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2110 |     }
2111 | 
2112 |     protected function reduceRule271($attributes) {
2113 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2114 |     }
2115 | 
2116 |     protected function reduceRule272($attributes) {
2117 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2118 |     }
2119 | 
2120 |     protected function reduceRule273($attributes) {
2121 |          $this->semValue = new Node\Expr\ShellExec($this->semStack[$this->stackPos-(3-2)], $attributes); 
2122 |     }
2123 | 
2124 |     protected function reduceRule274($attributes) {
2125 |          $this->semValue = new Node\Expr\Print_($this->semStack[$this->stackPos-(2-2)], $attributes); 
2126 |     }
2127 | 
2128 |     protected function reduceRule275($attributes) {
2129 |          $this->semValue = new Node\Expr\Yield_(null, null, $attributes); 
2130 |     }
2131 | 
2132 |     protected function reduceRule276($attributes) {
2133 |          $this->semValue = new Node\Expr\Closure(array('static' => false, 'byRef' => $this->semStack[$this->stackPos-(10-2)], 'params' => $this->semStack[$this->stackPos-(10-4)], 'uses' => $this->semStack[$this->stackPos-(10-6)], 'returnType' => $this->semStack[$this->stackPos-(10-7)], 'stmts' => $this->semStack[$this->stackPos-(10-9)]), $attributes); 
2134 |     }
2135 | 
2136 |     protected function reduceRule277($attributes) {
2137 |          $this->semValue = new Node\Expr\Closure(array('static' => true, 'byRef' => $this->semStack[$this->stackPos-(11-3)], 'params' => $this->semStack[$this->stackPos-(11-5)], 'uses' => $this->semStack[$this->stackPos-(11-7)], 'returnType' => $this->semStack[$this->stackPos-(11-8)], 'stmts' => $this->semStack[$this->stackPos-(11-10)]), $attributes); 
2138 |     }
2139 | 
2140 |     protected function reduceRule278($attributes) {
2141 |          $this->semValue = $this->semStack[$this->stackPos-(3-2)]; 
2142 |     }
2143 | 
2144 |     protected function reduceRule279($attributes) {
2145 |          $this->semValue = $this->semStack[$this->stackPos-(3-2)]; 
2146 |     }
2147 | 
2148 |     protected function reduceRule280($attributes) {
2149 |          $this->semValue = new Node\Expr\Yield_($this->semStack[$this->stackPos-(2-2)], null, $attributes); 
2150 |     }
2151 | 
2152 |     protected function reduceRule281($attributes) {
2153 |          $this->semValue = new Node\Expr\Yield_($this->semStack[$this->stackPos-(4-4)], $this->semStack[$this->stackPos-(4-2)], $attributes); 
2154 |     }
2155 | 
2156 |     protected function reduceRule282($attributes) {
2157 |          $this->semValue = new Node\Expr\Array_($this->semStack[$this->stackPos-(4-3)], $attributes); 
2158 |     }
2159 | 
2160 |     protected function reduceRule283($attributes) {
2161 |          $this->semValue = new Node\Expr\Array_($this->semStack[$this->stackPos-(3-2)], $attributes); 
2162 |     }
2163 | 
2164 |     protected function reduceRule284($attributes) {
2165 |          $this->semValue = new Node\Expr\ArrayDimFetch($this->semStack[$this->stackPos-(4-1)], $this->semStack[$this->stackPos-(4-3)], $attributes); 
2166 |     }
2167 | 
2168 |     protected function reduceRule285($attributes) {
2169 |          $this->semValue = new Node\Expr\ArrayDimFetch(new Node\Scalar\String_(Node\Scalar\String_::parse($this->semStack[$this->stackPos-(4-1)]), $attributes), $this->semStack[$this->stackPos-(4-3)], $attributes); 
2170 |     }
2171 | 
2172 |     protected function reduceRule286($attributes) {
2173 |          $this->semValue = new Node\Expr\ArrayDimFetch($this->semStack[$this->stackPos-(4-1)], $this->semStack[$this->stackPos-(4-3)], $attributes); 
2174 |     }
2175 | 
2176 |     protected function reduceRule287($attributes) {
2177 |          $this->semValue = new Node\Expr\ArrayDimFetch($this->semStack[$this->stackPos-(4-1)], $this->semStack[$this->stackPos-(4-3)], $attributes); 
2178 |     }
2179 | 
2180 |     protected function reduceRule288($attributes) {
2181 |          $this->semValue = new Node\Expr\New_($this->semStack[$this->stackPos-(4-2)], $this->semStack[$this->stackPos-(4-4)], array('generics' => $this->semStack[$this->stackPos-(4-3)]), $attributes); 
2182 |     }
2183 | 
2184 |     protected function reduceRule289($attributes) {
2185 |          $this->semValue = array(); 
2186 |     }
2187 | 
2188 |     protected function reduceRule290($attributes) {
2189 |          $this->semValue = $this->semStack[$this->stackPos-(4-3)]; 
2190 |     }
2191 | 
2192 |     protected function reduceRule291($attributes) {
2193 |          $this->semValue = array($this->semStack[$this->stackPos-(1-1)]); 
2194 |     }
2195 | 
2196 |     protected function reduceRule292($attributes) {
2197 |          $this->semStack[$this->stackPos-(3-1)][] = $this->semStack[$this->stackPos-(3-3)]; $this->semValue = $this->semStack[$this->stackPos-(3-1)]; 
2198 |     }
2199 | 
2200 |     protected function reduceRule293($attributes) {
2201 |          $this->semValue = new Node\Expr\ClosureUse(substr($this->semStack[$this->stackPos-(2-2)], 1), $this->semStack[$this->stackPos-(2-1)], $attributes); 
2202 |     }
2203 | 
2204 |     protected function reduceRule294($attributes) {
2205 |          $this->semValue = new Node\Expr\FuncCall($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], array('generics' => $this->semStack[$this->stackPos-(3-2)]), $attributes); 
2206 |     }
2207 | 
2208 |     protected function reduceRule295($attributes) {
2209 |          $this->semValue = new Node\Expr\StaticCall($this->semStack[$this->stackPos-(5-1)], $this->semStack[$this->stackPos-(5-3)], $this->semStack[$this->stackPos-(5-5)], array('generics' => $this->semStack[$this->stackPos-(5-4)]), $attributes); 
2210 |     }
2211 | 
2212 |     protected function reduceRule296($attributes) {
2213 |          $this->semValue = new Node\Expr\StaticCall($this->semStack[$this->stackPos-(7-1)], $this->semStack[$this->stackPos-(7-4)], $this->semStack[$this->stackPos-(7-7)], array('generics' => $this->semStack[$this->stackPos-(7-6)]), $attributes); 
2214 |     }
2215 | 
2216 |     protected function reduceRule297($attributes) {
2217 |         
2218 |             if ($this->semStack[$this->stackPos-(2-1)] instanceof Node\Expr\StaticPropertyFetch) {
2219 |                 $this->semValue = new Node\Expr\StaticCall($this->semStack[$this->stackPos-(2-1)]->class, new Node\Expr\Variable($this->semStack[$this->stackPos-(2-1)]->name, $attributes), $this->semStack[$this->stackPos-(2-2)], $attributes);
2220 |             } elseif ($this->semStack[$this->stackPos-(2-1)] instanceof Node\Expr\ArrayDimFetch) {
2221 |                 $tmp = $this->semStack[$this->stackPos-(2-1)];
2222 |                 while ($tmp->var instanceof Node\Expr\ArrayDimFetch) {
2223 |                     $tmp = $tmp->var;
2224 |                 }
2225 | 
2226 |                 $this->semValue = new Node\Expr\StaticCall($tmp->var->class, $this->semStack[$this->stackPos-(2-1)], $this->semStack[$this->stackPos-(2-2)], $attributes);
2227 |                 $tmp->var = new Node\Expr\Variable($tmp->var->name, $attributes);
2228 |             } else {
2229 |                 throw new \Exception;
2230 |             }
2231 |           
2232 |     }
2233 | 
2234 |     protected function reduceRule298($attributes) {
2235 |          $this->semValue = new Node\Expr\FuncCall($this->semStack[$this->stackPos-(2-1)], $this->semStack[$this->stackPos-(2-2)], $attributes); 
2236 |     }
2237 | 
2238 |     protected function reduceRule299($attributes) {
2239 |          $this->semValue = new Node\Expr\ArrayDimFetch($this->semStack[$this->stackPos-(4-1)], $this->semStack[$this->stackPos-(4-3)], $attributes); 
2240 |     }
2241 | 
2242 |     protected function reduceRule300($attributes) {
2243 |          $this->semValue = new Node\Name($this->semStack[$this->stackPos-(1-1)], $attributes); 
2244 |     }
2245 | 
2246 |     protected function reduceRule301($attributes) {
2247 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2248 |     }
2249 | 
2250 |     protected function reduceRule302($attributes) {
2251 |          $this->semValue = new Node\Name($this->semStack[$this->stackPos-(1-1)], $attributes); 
2252 |     }
2253 | 
2254 |     protected function reduceRule303($attributes) {
2255 |          $this->semValue = new Node\Name\FullyQualified($this->semStack[$this->stackPos-(2-2)], $attributes); 
2256 |     }
2257 | 
2258 |     protected function reduceRule304($attributes) {
2259 |          $this->semValue = new Node\Name\Relative($this->semStack[$this->stackPos-(3-3)], $attributes); 
2260 |     }
2261 | 
2262 |     protected function reduceRule305($attributes) {
2263 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2264 |     }
2265 | 
2266 |     protected function reduceRule306($attributes) {
2267 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2268 |     }
2269 | 
2270 |     protected function reduceRule307($attributes) {
2271 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2272 |     }
2273 | 
2274 |     protected function reduceRule308($attributes) {
2275 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2276 |     }
2277 | 
2278 |     protected function reduceRule309($attributes) {
2279 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2280 |     }
2281 | 
2282 |     protected function reduceRule310($attributes) {
2283 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2284 |     }
2285 | 
2286 |     protected function reduceRule311($attributes) {
2287 |          $this->semValue = new Node\Expr\PropertyFetch($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2288 |     }
2289 | 
2290 |     protected function reduceRule312($attributes) {
2291 |          $this->semValue = new Node\Expr\PropertyFetch($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2292 |     }
2293 | 
2294 |     protected function reduceRule313($attributes) {
2295 |          $this->semValue = new Node\Expr\ArrayDimFetch($this->semStack[$this->stackPos-(4-1)], $this->semStack[$this->stackPos-(4-3)], $attributes); 
2296 |     }
2297 | 
2298 |     protected function reduceRule314($attributes) {
2299 |          $this->semValue = new Node\Expr\ArrayDimFetch($this->semStack[$this->stackPos-(4-1)], $this->semStack[$this->stackPos-(4-3)], $attributes); 
2300 |     }
2301 | 
2302 |     protected function reduceRule315($attributes) {
2303 |          $this->semValue = null; 
2304 |     }
2305 | 
2306 |     protected function reduceRule316($attributes) {
2307 |          $this->semValue = null; 
2308 |     }
2309 | 
2310 |     protected function reduceRule317($attributes) {
2311 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2312 |     }
2313 | 
2314 |     protected function reduceRule318($attributes) {
2315 |          $this->semValue = array(); 
2316 |     }
2317 | 
2318 |     protected function reduceRule319($attributes) {
2319 |          $this->semValue = array(Node\Scalar\String_::parseEscapeSequences($this->semStack[$this->stackPos-(1-1)], '`')); 
2320 |     }
2321 | 
2322 |     protected function reduceRule320($attributes) {
2323 |          foreach ($this->semStack[$this->stackPos-(1-1)] as &$s) { if (is_string($s)) { $s = Node\Scalar\String_::parseEscapeSequences($s, '`'); } }; $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2324 |     }
2325 | 
2326 |     protected function reduceRule321($attributes) {
2327 |          $this->semValue = array(); 
2328 |     }
2329 | 
2330 |     protected function reduceRule322($attributes) {
2331 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2332 |     }
2333 | 
2334 |     protected function reduceRule323($attributes) {
2335 |          $this->semValue = new Node\Scalar\LNumber(Node\Scalar\LNumber::parse($this->semStack[$this->stackPos-(1-1)]), $attributes); 
2336 |     }
2337 | 
2338 |     protected function reduceRule324($attributes) {
2339 |          $this->semValue = new Node\Scalar\DNumber(Node\Scalar\DNumber::parse($this->semStack[$this->stackPos-(1-1)]), $attributes); 
2340 |     }
2341 | 
2342 |     protected function reduceRule325($attributes) {
2343 |          $this->semValue = new Node\Scalar\String_(Node\Scalar\String_::parse($this->semStack[$this->stackPos-(1-1)]), $attributes); 
2344 |     }
2345 | 
2346 |     protected function reduceRule326($attributes) {
2347 |          $this->semValue = new Node\Scalar\MagicConst\Line($attributes); 
2348 |     }
2349 | 
2350 |     protected function reduceRule327($attributes) {
2351 |          $this->semValue = new Node\Scalar\MagicConst\File($attributes); 
2352 |     }
2353 | 
2354 |     protected function reduceRule328($attributes) {
2355 |          $this->semValue = new Node\Scalar\MagicConst\Dir($attributes); 
2356 |     }
2357 | 
2358 |     protected function reduceRule329($attributes) {
2359 |          $this->semValue = new Node\Scalar\MagicConst\Class_($attributes); 
2360 |     }
2361 | 
2362 |     protected function reduceRule330($attributes) {
2363 |          $this->semValue = new Node\Scalar\MagicConst\Trait_($attributes); 
2364 |     }
2365 | 
2366 |     protected function reduceRule331($attributes) {
2367 |          $this->semValue = new Node\Scalar\MagicConst\Method($attributes); 
2368 |     }
2369 | 
2370 |     protected function reduceRule332($attributes) {
2371 |          $this->semValue = new Node\Scalar\MagicConst\Function_($attributes); 
2372 |     }
2373 | 
2374 |     protected function reduceRule333($attributes) {
2375 |          $this->semValue = new Node\Scalar\MagicConst\Namespace_($attributes); 
2376 |     }
2377 | 
2378 |     protected function reduceRule334($attributes) {
2379 |          $this->semValue = new Node\Scalar\String_(Node\Scalar\String_::parseDocString($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-2)]), $attributes); 
2380 |     }
2381 | 
2382 |     protected function reduceRule335($attributes) {
2383 |          $this->semValue = new Node\Scalar\String_('', $attributes); 
2384 |     }
2385 | 
2386 |     protected function reduceRule336($attributes) {
2387 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2388 |     }
2389 | 
2390 |     protected function reduceRule337($attributes) {
2391 |          $this->semValue = new Node\Expr\ClassConstFetch($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2392 |     }
2393 | 
2394 |     protected function reduceRule338($attributes) {
2395 |          $this->semValue = new Node\Expr\ConstFetch($this->semStack[$this->stackPos-(1-1)], $attributes); 
2396 |     }
2397 | 
2398 |     protected function reduceRule339($attributes) {
2399 |          $this->semValue = new Node\Expr\Array_($this->semStack[$this->stackPos-(4-3)], $attributes); 
2400 |     }
2401 | 
2402 |     protected function reduceRule340($attributes) {
2403 |          $this->semValue = new Node\Expr\Array_($this->semStack[$this->stackPos-(3-2)], $attributes); 
2404 |     }
2405 | 
2406 |     protected function reduceRule341($attributes) {
2407 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2408 |     }
2409 | 
2410 |     protected function reduceRule342($attributes) {
2411 |          $this->semValue = new Node\Expr\BinaryOp\BooleanOr($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2412 |     }
2413 | 
2414 |     protected function reduceRule343($attributes) {
2415 |          $this->semValue = new Node\Expr\BinaryOp\BooleanAnd($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2416 |     }
2417 | 
2418 |     protected function reduceRule344($attributes) {
2419 |          $this->semValue = new Node\Expr\BinaryOp\LogicalOr($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2420 |     }
2421 | 
2422 |     protected function reduceRule345($attributes) {
2423 |          $this->semValue = new Node\Expr\BinaryOp\LogicalAnd($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2424 |     }
2425 | 
2426 |     protected function reduceRule346($attributes) {
2427 |          $this->semValue = new Node\Expr\BinaryOp\LogicalXor($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2428 |     }
2429 | 
2430 |     protected function reduceRule347($attributes) {
2431 |          $this->semValue = new Node\Expr\BinaryOp\BitwiseOr($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2432 |     }
2433 | 
2434 |     protected function reduceRule348($attributes) {
2435 |          $this->semValue = new Node\Expr\BinaryOp\BitwiseAnd($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2436 |     }
2437 | 
2438 |     protected function reduceRule349($attributes) {
2439 |          $this->semValue = new Node\Expr\BinaryOp\BitwiseXor($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2440 |     }
2441 | 
2442 |     protected function reduceRule350($attributes) {
2443 |          $this->semValue = new Node\Expr\BinaryOp\Concat($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2444 |     }
2445 | 
2446 |     protected function reduceRule351($attributes) {
2447 |          $this->semValue = new Node\Expr\BinaryOp\Plus($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2448 |     }
2449 | 
2450 |     protected function reduceRule352($attributes) {
2451 |          $this->semValue = new Node\Expr\BinaryOp\Minus($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2452 |     }
2453 | 
2454 |     protected function reduceRule353($attributes) {
2455 |          $this->semValue = new Node\Expr\BinaryOp\Mul($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2456 |     }
2457 | 
2458 |     protected function reduceRule354($attributes) {
2459 |          $this->semValue = new Node\Expr\BinaryOp\Div($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2460 |     }
2461 | 
2462 |     protected function reduceRule355($attributes) {
2463 |          $this->semValue = new Node\Expr\BinaryOp\Mod($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2464 |     }
2465 | 
2466 |     protected function reduceRule356($attributes) {
2467 |          $this->semValue = new Node\Expr\BinaryOp\ShiftLeft($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2468 |     }
2469 | 
2470 |     protected function reduceRule357($attributes) {
2471 |          $this->semValue = new Node\Expr\BinaryOp\ShiftRight($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2472 |     }
2473 | 
2474 |     protected function reduceRule358($attributes) {
2475 |          $this->semValue = new Node\Expr\BinaryOp\Pow($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2476 |     }
2477 | 
2478 |     protected function reduceRule359($attributes) {
2479 |          $this->semValue = new Node\Expr\UnaryPlus($this->semStack[$this->stackPos-(2-2)], $attributes); 
2480 |     }
2481 | 
2482 |     protected function reduceRule360($attributes) {
2483 |          $this->semValue = new Node\Expr\UnaryMinus($this->semStack[$this->stackPos-(2-2)], $attributes); 
2484 |     }
2485 | 
2486 |     protected function reduceRule361($attributes) {
2487 |          $this->semValue = new Node\Expr\BooleanNot($this->semStack[$this->stackPos-(2-2)], $attributes); 
2488 |     }
2489 | 
2490 |     protected function reduceRule362($attributes) {
2491 |          $this->semValue = new Node\Expr\BitwiseNot($this->semStack[$this->stackPos-(2-2)], $attributes); 
2492 |     }
2493 | 
2494 |     protected function reduceRule363($attributes) {
2495 |          $this->semValue = new Node\Expr\BinaryOp\Identical($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2496 |     }
2497 | 
2498 |     protected function reduceRule364($attributes) {
2499 |          $this->semValue = new Node\Expr\BinaryOp\NotIdentical($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2500 |     }
2501 | 
2502 |     protected function reduceRule365($attributes) {
2503 |          $this->semValue = new Node\Expr\BinaryOp\Equal($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2504 |     }
2505 | 
2506 |     protected function reduceRule366($attributes) {
2507 |          $this->semValue = new Node\Expr\BinaryOp\NotEqual($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2508 |     }
2509 | 
2510 |     protected function reduceRule367($attributes) {
2511 |          $this->semValue = new Node\Expr\BinaryOp\Smaller($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2512 |     }
2513 | 
2514 |     protected function reduceRule368($attributes) {
2515 |          $this->semValue = new Node\Expr\BinaryOp\SmallerOrEqual($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2516 |     }
2517 | 
2518 |     protected function reduceRule369($attributes) {
2519 |          $this->semValue = new Node\Expr\BinaryOp\Greater($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2520 |     }
2521 | 
2522 |     protected function reduceRule370($attributes) {
2523 |          $this->semValue = new Node\Expr\BinaryOp\GreaterOrEqual($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2524 |     }
2525 | 
2526 |     protected function reduceRule371($attributes) {
2527 |          $this->semValue = new Node\Expr\Ternary($this->semStack[$this->stackPos-(5-1)], $this->semStack[$this->stackPos-(5-3)], $this->semStack[$this->stackPos-(5-5)], $attributes); 
2528 |     }
2529 | 
2530 |     protected function reduceRule372($attributes) {
2531 |          $this->semValue = new Node\Expr\Ternary($this->semStack[$this->stackPos-(4-1)], null, $this->semStack[$this->stackPos-(4-4)], $attributes); 
2532 |     }
2533 | 
2534 |     protected function reduceRule373($attributes) {
2535 |          $this->semValue = new Node\Expr\ArrayDimFetch($this->semStack[$this->stackPos-(4-1)], $this->semStack[$this->stackPos-(4-3)], $attributes); 
2536 |     }
2537 | 
2538 |     protected function reduceRule374($attributes) {
2539 |          $this->semValue = $this->semStack[$this->stackPos-(3-2)]; 
2540 |     }
2541 | 
2542 |     protected function reduceRule375($attributes) {
2543 |          $this->semValue = new Node\Expr\ConstFetch($this->semStack[$this->stackPos-(1-1)], $attributes); 
2544 |     }
2545 | 
2546 |     protected function reduceRule376($attributes) {
2547 |          $this->semValue = new Node\Expr\ClassConstFetch($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2548 |     }
2549 | 
2550 |     protected function reduceRule377($attributes) {
2551 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2552 |     }
2553 | 
2554 |     protected function reduceRule378($attributes) {
2555 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2556 |     }
2557 | 
2558 |     protected function reduceRule379($attributes) {
2559 |          foreach ($this->semStack[$this->stackPos-(3-2)] as &$s) { if (is_string($s)) { $s = Node\Scalar\String_::parseEscapeSequences($s, '"'); } }; $this->semValue = new Node\Scalar\Encapsed($this->semStack[$this->stackPos-(3-2)], $attributes); 
2560 |     }
2561 | 
2562 |     protected function reduceRule380($attributes) {
2563 |          foreach ($this->semStack[$this->stackPos-(3-2)] as &$s) { if (is_string($s)) { $s = Node\Scalar\String_::parseEscapeSequences($s, null); } } $s = preg_replace('~(\r\n|\n|\r)$~', '', $s); if ('' === $s) array_pop($this->semStack[$this->stackPos-(3-2)]);; $this->semValue = new Node\Scalar\Encapsed($this->semStack[$this->stackPos-(3-2)], $attributes); 
2564 |     }
2565 | 
2566 |     protected function reduceRule381($attributes) {
2567 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2568 |     }
2569 | 
2570 |     protected function reduceRule382($attributes) {
2571 |          $this->semValue = 'class'; 
2572 |     }
2573 | 
2574 |     protected function reduceRule383($attributes) {
2575 |          $this->semValue = array(); 
2576 |     }
2577 | 
2578 |     protected function reduceRule384($attributes) {
2579 |          $this->semValue = $this->semStack[$this->stackPos-(2-1)]; 
2580 |     }
2581 | 
2582 |     protected function reduceRule385() {
2583 |         $this->semValue = $this->semStack[$this->stackPos];
2584 |     }
2585 | 
2586 |     protected function reduceRule386() {
2587 |         $this->semValue = $this->semStack[$this->stackPos];
2588 |     }
2589 | 
2590 |     protected function reduceRule387($attributes) {
2591 |          $this->semStack[$this->stackPos-(3-1)][] = $this->semStack[$this->stackPos-(3-3)]; $this->semValue = $this->semStack[$this->stackPos-(3-1)]; 
2592 |     }
2593 | 
2594 |     protected function reduceRule388($attributes) {
2595 |          $this->semValue = array($this->semStack[$this->stackPos-(1-1)]); 
2596 |     }
2597 | 
2598 |     protected function reduceRule389($attributes) {
2599 |          $this->semValue = new Node\Expr\ArrayItem($this->semStack[$this->stackPos-(3-3)], $this->semStack[$this->stackPos-(3-1)], false, $attributes); 
2600 |     }
2601 | 
2602 |     protected function reduceRule390($attributes) {
2603 |          $this->semValue = new Node\Expr\ArrayItem($this->semStack[$this->stackPos-(1-1)], null, false, $attributes); 
2604 |     }
2605 | 
2606 |     protected function reduceRule391($attributes) {
2607 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2608 |     }
2609 | 
2610 |     protected function reduceRule392($attributes) {
2611 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2612 |     }
2613 | 
2614 |     protected function reduceRule393($attributes) {
2615 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2616 |     }
2617 | 
2618 |     protected function reduceRule394($attributes) {
2619 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2620 |     }
2621 | 
2622 |     protected function reduceRule395($attributes) {
2623 |          $this->semValue = new Node\Expr\ArrayDimFetch($this->semStack[$this->stackPos-(6-2)], $this->semStack[$this->stackPos-(6-5)], $attributes); 
2624 |     }
2625 | 
2626 |     protected function reduceRule396($attributes) {
2627 |          $this->semValue = new Node\Expr\ArrayDimFetch($this->semStack[$this->stackPos-(4-1)], $this->semStack[$this->stackPos-(4-3)], $attributes); 
2628 |     }
2629 | 
2630 |     protected function reduceRule397($attributes) {
2631 |          $this->semValue = new Node\Expr\PropertyFetch($this->semStack[$this->stackPos-(3-1)], $this->semStack[$this->stackPos-(3-3)], $attributes); 
2632 |     }
2633 | 
2634 |     protected function reduceRule398($attributes) {
2635 |          $this->semValue = new Node\Expr\MethodCall($this->semStack[$this->stackPos-(4-1)], $this->semStack[$this->stackPos-(4-3)], $this->semStack[$this->stackPos-(4-4)], $attributes); 
2636 |     }
2637 | 
2638 |     protected function reduceRule399($attributes) {
2639 |          $this->semValue = new Node\Expr\FuncCall($this->semStack[$this->stackPos-(2-1)], $this->semStack[$this->stackPos-(2-2)], $attributes); 
2640 |     }
2641 | 
2642 |     protected function reduceRule400($attributes) {
2643 |          $this->semValue = new Node\Expr\ArrayDimFetch($this->semStack[$this->stackPos-(4-1)], $this->semStack[$this->stackPos-(4-3)], $attributes); 
2644 |     }
2645 | 
2646 |     protected function reduceRule401($attributes) {
2647 |          $this->semValue = new Node\Expr\ArrayDimFetch($this->semStack[$this->stackPos-(4-1)], $this->semStack[$this->stackPos-(4-3)], $attributes); 
2648 |     }
2649 | 
2650 |     protected function reduceRule402($attributes) {
2651 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2652 |     }
2653 | 
2654 |     protected function reduceRule403($attributes) {
2655 |          $this->semValue = $this->semStack[$this->stackPos-(3-2)]; 
2656 |     }
2657 | 
2658 |     protected function reduceRule404($attributes) {
2659 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2660 |     }
2661 | 
2662 |     protected function reduceRule405($attributes) {
2663 |          $this->semValue = new Node\Expr\Variable($this->semStack[$this->stackPos-(2-2)], $attributes); 
2664 |     }
2665 | 
2666 |     protected function reduceRule406($attributes) {
2667 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2668 |     }
2669 | 
2670 |     protected function reduceRule407($attributes) {
2671 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2672 |     }
2673 | 
2674 |     protected function reduceRule408($attributes) {
2675 |          $this->semValue = new Node\Expr\StaticPropertyFetch($this->semStack[$this->stackPos-(4-1)], $this->semStack[$this->stackPos-(4-4)], $attributes); 
2676 |     }
2677 | 
2678 |     protected function reduceRule409($attributes) {
2679 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2680 |     }
2681 | 
2682 |     protected function reduceRule410($attributes) {
2683 |          $this->semValue = new Node\Expr\StaticPropertyFetch($this->semStack[$this->stackPos-(3-1)], substr($this->semStack[$this->stackPos-(3-3)], 1), $attributes); 
2684 |     }
2685 | 
2686 |     protected function reduceRule411($attributes) {
2687 |          $this->semValue = new Node\Expr\StaticPropertyFetch($this->semStack[$this->stackPos-(6-1)], $this->semStack[$this->stackPos-(6-5)], $attributes); 
2688 |     }
2689 | 
2690 |     protected function reduceRule412($attributes) {
2691 |          $this->semValue = new Node\Expr\ArrayDimFetch($this->semStack[$this->stackPos-(4-1)], $this->semStack[$this->stackPos-(4-3)], $attributes); 
2692 |     }
2693 | 
2694 |     protected function reduceRule413($attributes) {
2695 |          $this->semValue = new Node\Expr\ArrayDimFetch($this->semStack[$this->stackPos-(4-1)], $this->semStack[$this->stackPos-(4-3)], $attributes); 
2696 |     }
2697 | 
2698 |     protected function reduceRule414($attributes) {
2699 |          $this->semValue = new Node\Expr\ArrayDimFetch($this->semStack[$this->stackPos-(4-1)], $this->semStack[$this->stackPos-(4-3)], $attributes); 
2700 |     }
2701 | 
2702 |     protected function reduceRule415($attributes) {
2703 |          $this->semValue = new Node\Expr\ArrayDimFetch($this->semStack[$this->stackPos-(4-1)], $this->semStack[$this->stackPos-(4-3)], $attributes); 
2704 |     }
2705 | 
2706 |     protected function reduceRule416($attributes) {
2707 |          $this->semValue = new Node\Expr\Variable(substr($this->semStack[$this->stackPos-(1-1)], 1), $attributes); 
2708 |     }
2709 | 
2710 |     protected function reduceRule417($attributes) {
2711 |          $this->semValue = new Node\Expr\Variable($this->semStack[$this->stackPos-(4-3)], $attributes); 
2712 |     }
2713 | 
2714 |     protected function reduceRule418($attributes) {
2715 |          $this->semValue = null; 
2716 |     }
2717 | 
2718 |     protected function reduceRule419($attributes) {
2719 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2720 |     }
2721 | 
2722 |     protected function reduceRule420($attributes) {
2723 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2724 |     }
2725 | 
2726 |     protected function reduceRule421($attributes) {
2727 |          $this->semValue = $this->semStack[$this->stackPos-(3-2)]; 
2728 |     }
2729 | 
2730 |     protected function reduceRule422($attributes) {
2731 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2732 |     }
2733 | 
2734 |     protected function reduceRule423($attributes) {
2735 |          $this->semValue = new Node\Expr\List_($this->semStack[$this->stackPos-(4-3)], $attributes); 
2736 |     }
2737 | 
2738 |     protected function reduceRule424($attributes) {
2739 |          $this->semStack[$this->stackPos-(3-1)][] = $this->semStack[$this->stackPos-(3-3)]; $this->semValue = $this->semStack[$this->stackPos-(3-1)]; 
2740 |     }
2741 | 
2742 |     protected function reduceRule425($attributes) {
2743 |          $this->semValue = array($this->semStack[$this->stackPos-(1-1)]); 
2744 |     }
2745 | 
2746 |     protected function reduceRule426($attributes) {
2747 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2748 |     }
2749 | 
2750 |     protected function reduceRule427($attributes) {
2751 |          $this->semValue = $this->semStack[$this->stackPos-(1-1)]; 
2752 |     }
2753 | 
2754 |     protected function reduceRule428($attributes) {
2755 |          $this->semValue = null; 
2756 |     }
2757 | 
2758 |     protected function reduceRule429($attributes) {
2759 |          $this->semValue = array(); 
2760 |     }
2761 | 
2762 |     protected function reduceRule430($attributes) {
2763 |          $this->semValue = $this->semStack[$this->stackPos-(2-1)]; 
2764 |     }
2765 | 
2766 |     protected function reduceRule431($attributes) {
2767 |          $this->semStack[$this->stackPos-(3-1)][] = $this->semStack[$this->stackPos-(3-3)]; $this->semValue = $this->semStack[$this->stackPos-(3-1)]; 
2768 |     }
2769 | 
2770 |     protected function reduceRule432($attributes) {
2771 |          $this->semValue = array($this->semStack[$this->stackPos-(1-1)]); 
2772 |     }
2773 | 
2774 |     protected function reduceRule433($attributes) {
2775 |          $this->semValue = new Node\Expr\ArrayItem($this->semStack[$this->stackPos-(3-3)], $this->semStack[$this->stackPos-(3-1)], false, $attributes); 
2776 |     }
2777 | 
2778 |     protected function reduceRule434($attributes) {
2779 |          $this->semValue = new Node\Expr\ArrayItem($this->semStack[$this->stackPos-(1-1)], null, false, $attributes); 
2780 |     }
2781 | 
2782 |     protected function reduceRule435($attributes) {
2783 |          $this->semValue = new Node\Expr\ArrayItem($this->semStack[$this->stackPos-(4-4)], $this->semStack[$this->stackPos-(4-1)], true, $attributes); 
2784 |     }
2785 | 
2786 |     protected function reduceRule436($attributes) {
2787 |          $this->semValue = new Node\Expr\ArrayItem($this->semStack[$this->stackPos-(2-2)], null, true, $attributes); 
2788 |     }
2789 | 
2790 |     protected function reduceRule437($attributes) {
2791 |          $this->semStack[$this->stackPos-(2-1)][] = $this->semStack[$this->stackPos-(2-2)]; $this->semValue = $this->semStack[$this->stackPos-(2-1)]; 
2792 |     }
2793 | 
2794 |     protected function reduceRule438($attributes) {
2795 |          $this->semStack[$this->stackPos-(2-1)][] = $this->semStack[$this->stackPos-(2-2)]; $this->semValue = $this->semStack[$this->stackPos-(2-1)]; 
2796 |     }
2797 | 
2798 |     protected function reduceRule439($attributes) {
2799 |          $this->semValue = array($this->semStack[$this->stackPos-(1-1)]); 
2800 |     }
2801 | 
2802 |     protected function reduceRule440($attributes) {
2803 |          $this->semValue = array($this->semStack[$this->stackPos-(2-1)], $this->semStack[$this->stackPos-(2-2)]); 
2804 |     }
2805 | 
2806 |     protected function reduceRule441($attributes) {
2807 |          $this->semValue = new Node\Expr\Variable(substr($this->semStack[$this->stackPos-(1-1)], 1), $attributes); 
2808 |     }
2809 | 
2810 |     protected function reduceRule442($attributes) {
2811 |          $this->semValue = new Node\Expr\ArrayDimFetch(new Node\Expr\Variable(substr($this->semStack[$this->stackPos-(4-1)], 1), $attributes), $this->semStack[$this->stackPos-(4-3)], $attributes); 
2812 |     }
2813 | 
2814 |     protected function reduceRule443($attributes) {
2815 |          $this->semValue = new Node\Expr\PropertyFetch(new Node\Expr\Variable(substr($this->semStack[$this->stackPos-(3-1)], 1), $attributes), $this->semStack[$this->stackPos-(3-3)], $attributes); 
2816 |     }
2817 | 
2818 |     protected function reduceRule444($attributes) {
2819 |          $this->semValue = new Node\Expr\Variable($this->semStack[$this->stackPos-(3-2)], $attributes); 
2820 |     }
2821 | 
2822 |     protected function reduceRule445($attributes) {
2823 |          $this->semValue = new Node\Expr\Variable($this->semStack[$this->stackPos-(3-2)], $attributes); 
2824 |     }
2825 | 
2826 |     protected function reduceRule446($attributes) {
2827 |          $this->semValue = new Node\Expr\ArrayDimFetch(new Node\Expr\Variable($this->semStack[$this->stackPos-(6-2)], $attributes), $this->semStack[$this->stackPos-(6-4)], $attributes); 
2828 |     }
2829 | 
2830 |     protected function reduceRule447($attributes) {
2831 |          $this->semValue = $this->semStack[$this->stackPos-(3-2)]; 
2832 |     }
2833 | 
2834 |     protected function reduceRule448($attributes) {
2835 |          $this->semValue = new Node\Scalar\String_($this->semStack[$this->stackPos-(1-1)], $attributes); 
2836 |     }
2837 | 
2838 |     protected function reduceRule449($attributes) {
2839 |          $this->semValue = new Node\Scalar\String_($this->semStack[$this->stackPos-(1-1)], $attributes); 
2840 |     }
2841 | 
2842 |     protected function reduceRule450($attributes) {
2843 |          $this->semValue = new Node\Expr\Variable(substr($this->semStack[$this->stackPos-(1-1)], 1), $attributes); 
2844 |     }
2845 | }
2846 | 


--------------------------------------------------------------------------------
/lib/bootstrap.php:
--------------------------------------------------------------------------------
 1 | unregister();
15 | $new_autoloader->register(true);
16 | 
17 | foreach (get_declared_classes() as $class) {
18 |     if (strpos($class, "ComposerAutoloaderInit") === 0) {
19 |         $r = new ReflectionProperty($class, "loader");
20 |         $r->setAccessible(true);
21 |         $r->setValue($new_autoloader);
22 |     }
23 | }
24 | 


--------------------------------------------------------------------------------