diff --git a/composer.lock b/composer.lock index abc73fab7..730541402 100644 --- a/composer.lock +++ b/composer.lock @@ -1786,16 +1786,16 @@ }, { "name": "nikic/php-parser", - "version": "v4.3.0", + "version": "v4.10.4", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "9a9981c347c5c49d6dfe5cf826bb882b824080dc" + "reference": "c6d052fc58cb876152f89f532b95a8d7907e7f0e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/9a9981c347c5c49d6dfe5cf826bb882b824080dc", - "reference": "9a9981c347c5c49d6dfe5cf826bb882b824080dc", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/c6d052fc58cb876152f89f532b95a8d7907e7f0e", + "reference": "c6d052fc58cb876152f89f532b95a8d7907e7f0e", "shasum": "" }, "require": { @@ -1803,8 +1803,8 @@ "php": ">=7.0" }, "require-dev": { - "ircmaxell/php-yacc": "0.0.5", - "phpunit/phpunit": "^6.5 || ^7.0 || ^8.0" + "ircmaxell/php-yacc": "^0.0.7", + "phpunit/phpunit": "^6.5 || ^7.0 || ^8.0 || ^9.0" }, "bin": [ "bin/php-parse" @@ -1812,7 +1812,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "4.3-dev" + "dev-master": "4.9-dev" } }, "autoload": { @@ -1834,7 +1834,11 @@ "parser", "php" ], - "time": "2019-11-08T13:50:10+00:00" + "support": { + "issues": "https://github.com/nikic/PHP-Parser/issues", + "source": "https://github.com/nikic/PHP-Parser/tree/v4.10.4" + }, + "time": "2020-12-20T10:01:03+00:00" }, { "name": "opis/closure", diff --git a/composer/InstalledVersions.php b/composer/InstalledVersions.php index d9903df98..a888736ce 100644 --- a/composer/InstalledVersions.php +++ b/composer/InstalledVersions.php @@ -29,7 +29,7 @@ class InstalledVersions 'aliases' => array ( ), - 'reference' => '47d9890329b4e3a19ead2a3c90727963bcd1cca3', + 'reference' => '80cbffbe19083ba1c5a707f8353c1736a14a9c2e', 'name' => 'nextcloud/3rdparty', ), 'versions' => @@ -284,7 +284,7 @@ class InstalledVersions 'aliases' => array ( ), - 'reference' => '47d9890329b4e3a19ead2a3c90727963bcd1cca3', + 'reference' => '80cbffbe19083ba1c5a707f8353c1736a14a9c2e', ), 'nextcloud/lognormalizer' => array ( @@ -297,12 +297,12 @@ class InstalledVersions ), 'nikic/php-parser' => array ( - 'pretty_version' => 'v4.3.0', - 'version' => '4.3.0.0', + 'pretty_version' => 'v4.10.4', + 'version' => '4.10.4.0', 'aliases' => array ( ), - 'reference' => '9a9981c347c5c49d6dfe5cf826bb882b824080dc', + 'reference' => 'c6d052fc58cb876152f89f532b95a8d7907e7f0e', ), 'opis/closure' => array ( diff --git a/composer/autoload_classmap.php b/composer/autoload_classmap.php index 470ef5551..5d7216d35 100644 --- a/composer/autoload_classmap.php +++ b/composer/autoload_classmap.php @@ -1789,10 +1789,16 @@ 'PhpParser\\JsonDecoder' => $vendorDir . '/nikic/php-parser/lib/PhpParser/JsonDecoder.php', 'PhpParser\\Lexer' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer.php', 'PhpParser\\Lexer\\Emulative' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/Emulative.php', + 'PhpParser\\Lexer\\TokenEmulator\\AttributeEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/AttributeEmulator.php', 'PhpParser\\Lexer\\TokenEmulator\\CoaleseEqualTokenEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/CoaleseEqualTokenEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\FlexibleDocStringEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/FlexibleDocStringEmulator.php', 'PhpParser\\Lexer\\TokenEmulator\\FnTokenEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/FnTokenEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\KeywordEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/KeywordEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\MatchTokenEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/MatchTokenEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\NullsafeTokenEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/NullsafeTokenEmulator.php', 'PhpParser\\Lexer\\TokenEmulator\\NumericLiteralSeparatorEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/NumericLiteralSeparatorEmulator.php', - 'PhpParser\\Lexer\\TokenEmulator\\TokenEmulatorInterface' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/TokenEmulatorInterface.php', + 'PhpParser\\Lexer\\TokenEmulator\\ReverseEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/ReverseEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\TokenEmulator' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/TokenEmulator.php', 'PhpParser\\NameContext' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NameContext.php', 'PhpParser\\Node' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node.php', 'PhpParser\\NodeAbstract' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NodeAbstract.php', @@ -1806,7 +1812,11 @@ 'PhpParser\\NodeVisitor\\FindingVisitor' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NodeVisitor/FindingVisitor.php', 'PhpParser\\NodeVisitor\\FirstFindingVisitor' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NodeVisitor/FirstFindingVisitor.php', 'PhpParser\\NodeVisitor\\NameResolver' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NodeVisitor/NameResolver.php', + 'PhpParser\\NodeVisitor\\NodeConnectingVisitor' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NodeVisitor/NodeConnectingVisitor.php', + 'PhpParser\\NodeVisitor\\ParentConnectingVisitor' => $vendorDir . '/nikic/php-parser/lib/PhpParser/NodeVisitor/ParentConnectingVisitor.php', 'PhpParser\\Node\\Arg' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Arg.php', + 'PhpParser\\Node\\Attribute' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Attribute.php', + 'PhpParser\\Node\\AttributeGroup' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/AttributeGroup.php', 'PhpParser\\Node\\Const_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Const_.php', 'PhpParser\\Node\\Expr' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr.php', 'PhpParser\\Node\\Expr\\ArrayDimFetch' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/ArrayDimFetch.php', @@ -1882,8 +1892,11 @@ 'PhpParser\\Node\\Expr\\Instanceof_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Instanceof_.php', 'PhpParser\\Node\\Expr\\Isset_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Isset_.php', 'PhpParser\\Node\\Expr\\List_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/List_.php', + 'PhpParser\\Node\\Expr\\Match_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Match_.php', 'PhpParser\\Node\\Expr\\MethodCall' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/MethodCall.php', 'PhpParser\\Node\\Expr\\New_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/New_.php', + 'PhpParser\\Node\\Expr\\NullsafeMethodCall' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/NullsafeMethodCall.php', + 'PhpParser\\Node\\Expr\\NullsafePropertyFetch' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/NullsafePropertyFetch.php', 'PhpParser\\Node\\Expr\\PostDec' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/PostDec.php', 'PhpParser\\Node\\Expr\\PostInc' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/PostInc.php', 'PhpParser\\Node\\Expr\\PreDec' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/PreDec.php', @@ -1894,6 +1907,7 @@ 'PhpParser\\Node\\Expr\\StaticCall' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/StaticCall.php', 'PhpParser\\Node\\Expr\\StaticPropertyFetch' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/StaticPropertyFetch.php', 'PhpParser\\Node\\Expr\\Ternary' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Ternary.php', + 'PhpParser\\Node\\Expr\\Throw_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Throw_.php', 'PhpParser\\Node\\Expr\\UnaryMinus' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/UnaryMinus.php', 'PhpParser\\Node\\Expr\\UnaryPlus' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/UnaryPlus.php', 'PhpParser\\Node\\Expr\\Variable' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Variable.php', @@ -1901,6 +1915,7 @@ 'PhpParser\\Node\\Expr\\Yield_' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Expr/Yield_.php', 'PhpParser\\Node\\FunctionLike' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/FunctionLike.php', 'PhpParser\\Node\\Identifier' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Identifier.php', + 'PhpParser\\Node\\MatchArm' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/MatchArm.php', 'PhpParser\\Node\\Name' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Name.php', 'PhpParser\\Node\\Name\\FullyQualified' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Name/FullyQualified.php', 'PhpParser\\Node\\Name\\Relative' => $vendorDir . '/nikic/php-parser/lib/PhpParser/Node/Name/Relative.php', diff --git a/composer/autoload_static.php b/composer/autoload_static.php index ddc67198f..cf2ef37a0 100644 --- a/composer/autoload_static.php +++ b/composer/autoload_static.php @@ -2291,10 +2291,16 @@ class ComposerStaticInit2f23f73bc0cc116b4b1eee1521aa8652 'PhpParser\\JsonDecoder' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/JsonDecoder.php', 'PhpParser\\Lexer' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer.php', 'PhpParser\\Lexer\\Emulative' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/Emulative.php', + 'PhpParser\\Lexer\\TokenEmulator\\AttributeEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/AttributeEmulator.php', 'PhpParser\\Lexer\\TokenEmulator\\CoaleseEqualTokenEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/CoaleseEqualTokenEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\FlexibleDocStringEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/FlexibleDocStringEmulator.php', 'PhpParser\\Lexer\\TokenEmulator\\FnTokenEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/FnTokenEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\KeywordEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/KeywordEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\MatchTokenEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/MatchTokenEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\NullsafeTokenEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/NullsafeTokenEmulator.php', 'PhpParser\\Lexer\\TokenEmulator\\NumericLiteralSeparatorEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/NumericLiteralSeparatorEmulator.php', - 'PhpParser\\Lexer\\TokenEmulator\\TokenEmulatorInterface' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/TokenEmulatorInterface.php', + 'PhpParser\\Lexer\\TokenEmulator\\ReverseEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/ReverseEmulator.php', + 'PhpParser\\Lexer\\TokenEmulator\\TokenEmulator' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/TokenEmulator.php', 'PhpParser\\NameContext' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NameContext.php', 'PhpParser\\Node' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node.php', 'PhpParser\\NodeAbstract' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NodeAbstract.php', @@ -2308,7 +2314,11 @@ class ComposerStaticInit2f23f73bc0cc116b4b1eee1521aa8652 'PhpParser\\NodeVisitor\\FindingVisitor' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NodeVisitor/FindingVisitor.php', 'PhpParser\\NodeVisitor\\FirstFindingVisitor' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NodeVisitor/FirstFindingVisitor.php', 'PhpParser\\NodeVisitor\\NameResolver' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NodeVisitor/NameResolver.php', + 'PhpParser\\NodeVisitor\\NodeConnectingVisitor' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NodeVisitor/NodeConnectingVisitor.php', + 'PhpParser\\NodeVisitor\\ParentConnectingVisitor' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/NodeVisitor/ParentConnectingVisitor.php', 'PhpParser\\Node\\Arg' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Arg.php', + 'PhpParser\\Node\\Attribute' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Attribute.php', + 'PhpParser\\Node\\AttributeGroup' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/AttributeGroup.php', 'PhpParser\\Node\\Const_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Const_.php', 'PhpParser\\Node\\Expr' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr.php', 'PhpParser\\Node\\Expr\\ArrayDimFetch' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/ArrayDimFetch.php', @@ -2384,8 +2394,11 @@ class ComposerStaticInit2f23f73bc0cc116b4b1eee1521aa8652 'PhpParser\\Node\\Expr\\Instanceof_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Instanceof_.php', 'PhpParser\\Node\\Expr\\Isset_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Isset_.php', 'PhpParser\\Node\\Expr\\List_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/List_.php', + 'PhpParser\\Node\\Expr\\Match_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Match_.php', 'PhpParser\\Node\\Expr\\MethodCall' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/MethodCall.php', 'PhpParser\\Node\\Expr\\New_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/New_.php', + 'PhpParser\\Node\\Expr\\NullsafeMethodCall' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/NullsafeMethodCall.php', + 'PhpParser\\Node\\Expr\\NullsafePropertyFetch' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/NullsafePropertyFetch.php', 'PhpParser\\Node\\Expr\\PostDec' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/PostDec.php', 'PhpParser\\Node\\Expr\\PostInc' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/PostInc.php', 'PhpParser\\Node\\Expr\\PreDec' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/PreDec.php', @@ -2396,6 +2409,7 @@ class ComposerStaticInit2f23f73bc0cc116b4b1eee1521aa8652 'PhpParser\\Node\\Expr\\StaticCall' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/StaticCall.php', 'PhpParser\\Node\\Expr\\StaticPropertyFetch' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/StaticPropertyFetch.php', 'PhpParser\\Node\\Expr\\Ternary' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Ternary.php', + 'PhpParser\\Node\\Expr\\Throw_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Throw_.php', 'PhpParser\\Node\\Expr\\UnaryMinus' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/UnaryMinus.php', 'PhpParser\\Node\\Expr\\UnaryPlus' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/UnaryPlus.php', 'PhpParser\\Node\\Expr\\Variable' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Variable.php', @@ -2403,6 +2417,7 @@ class ComposerStaticInit2f23f73bc0cc116b4b1eee1521aa8652 'PhpParser\\Node\\Expr\\Yield_' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Expr/Yield_.php', 'PhpParser\\Node\\FunctionLike' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/FunctionLike.php', 'PhpParser\\Node\\Identifier' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Identifier.php', + 'PhpParser\\Node\\MatchArm' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/MatchArm.php', 'PhpParser\\Node\\Name' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Name.php', 'PhpParser\\Node\\Name\\FullyQualified' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Name/FullyQualified.php', 'PhpParser\\Node\\Name\\Relative' => __DIR__ . '/..' . '/nikic/php-parser/lib/PhpParser/Node/Name/Relative.php', diff --git a/composer/installed.json b/composer/installed.json index eefbd2b8d..13630e06e 100644 --- a/composer/installed.json +++ b/composer/installed.json @@ -1864,17 +1864,17 @@ }, { "name": "nikic/php-parser", - "version": "v4.3.0", - "version_normalized": "4.3.0.0", + "version": "v4.10.4", + "version_normalized": "4.10.4.0", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "9a9981c347c5c49d6dfe5cf826bb882b824080dc" + "reference": "c6d052fc58cb876152f89f532b95a8d7907e7f0e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/9a9981c347c5c49d6dfe5cf826bb882b824080dc", - "reference": "9a9981c347c5c49d6dfe5cf826bb882b824080dc", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/c6d052fc58cb876152f89f532b95a8d7907e7f0e", + "reference": "c6d052fc58cb876152f89f532b95a8d7907e7f0e", "shasum": "" }, "require": { @@ -1882,17 +1882,17 @@ "php": ">=7.0" }, "require-dev": { - "ircmaxell/php-yacc": "0.0.5", - "phpunit/phpunit": "^6.5 || ^7.0 || ^8.0" + "ircmaxell/php-yacc": "^0.0.7", + "phpunit/phpunit": "^6.5 || ^7.0 || ^8.0 || ^9.0" }, - "time": "2019-11-08T13:50:10+00:00", + "time": "2020-12-20T10:01:03+00:00", "bin": [ "bin/php-parse" ], "type": "library", "extra": { "branch-alias": { - "dev-master": "4.3-dev" + "dev-master": "4.9-dev" } }, "installation-source": "dist", @@ -1915,6 +1915,10 @@ "parser", "php" ], + "support": { + "issues": "https://github.com/nikic/PHP-Parser/issues", + "source": "https://github.com/nikic/PHP-Parser/tree/v4.10.4" + }, "install-path": "../nikic/php-parser" }, { diff --git a/composer/installed.php b/composer/installed.php index d8988b993..550985a09 100644 --- a/composer/installed.php +++ b/composer/installed.php @@ -6,7 +6,7 @@ 'aliases' => array ( ), - 'reference' => '47d9890329b4e3a19ead2a3c90727963bcd1cca3', + 'reference' => '80cbffbe19083ba1c5a707f8353c1736a14a9c2e', 'name' => 'nextcloud/3rdparty', ), 'versions' => @@ -261,7 +261,7 @@ 'aliases' => array ( ), - 'reference' => '47d9890329b4e3a19ead2a3c90727963bcd1cca3', + 'reference' => '80cbffbe19083ba1c5a707f8353c1736a14a9c2e', ), 'nextcloud/lognormalizer' => array ( @@ -274,12 +274,12 @@ ), 'nikic/php-parser' => array ( - 'pretty_version' => 'v4.3.0', - 'version' => '4.3.0.0', + 'pretty_version' => 'v4.10.4', + 'version' => '4.10.4.0', 'aliases' => array ( ), - 'reference' => '9a9981c347c5c49d6dfe5cf826bb882b824080dc', + 'reference' => 'c6d052fc58cb876152f89f532b95a8d7907e7f0e', ), 'opis/closure' => array ( diff --git a/nikic/php-parser/.gitattributes b/nikic/php-parser/.gitattributes deleted file mode 100644 index a6c4b04c9..000000000 --- a/nikic/php-parser/.gitattributes +++ /dev/null @@ -1,8 +0,0 @@ -/test export-ignore -/test_old export-ignore -/doc export-ignore -CHANGELOG.md export-ignore -.travis.yml export-ignore -phpunit.xml.dist export-ignore -UPGRADE-*.md export-ignore -.gitignore export-ignore diff --git a/nikic/php-parser/.github/workflows/main.yml b/nikic/php-parser/.github/workflows/main.yml new file mode 100644 index 000000000..426d4c83d --- /dev/null +++ b/nikic/php-parser/.github/workflows/main.yml @@ -0,0 +1,86 @@ +# https://help.github.com/en/categories/automating-your-workflow-with-github-actions +name: Main +on: + push: + pull_request: + +jobs: + tests_70: + runs-on: "ubuntu-latest" + name: "PHP 7.0 Unit Tests" + steps: + - name: "Checkout" + uses: "actions/checkout@v2" + - name: "Install PHP" + uses: "shivammathur/setup-php@v2" + with: + coverage: "xdebug" + php-version: "7.0" + tools: composer:v2 + - name: "Install dependencies" + run: | + composer require php-coveralls/php-coveralls:^2.2 --dev --no-update + composer update --no-progress --prefer-dist + - name: "Tests" + run: "php vendor/bin/phpunit --coverage-clover build/logs/clover.xml" + - name: Coveralls + env: + COVERALLS_REPO_TOKEN: ${{ secrets.GITHUB_TOKEN }} + run: "php vendor/bin/php-coveralls" + if: ${{ success() }} + tests: + runs-on: "ubuntu-latest" + name: "PHP ${{ matrix.php-version }} Unit Tests" + strategy: + matrix: + php-version: + - "7.1" + - "7.2" + - "7.3" + - "7.4" + - "8.0" + steps: + - name: "Checkout" + uses: "actions/checkout@v2" + - name: "Install PHP" + uses: "shivammathur/setup-php@v2" + with: + coverage: "none" + php-version: "${{ matrix.php-version }}" + tools: composer:v2 + - name: "Install dependencies" + run: "composer update --no-progress --prefer-dist" + - name: "PHPUnit" + run: "php vendor/bin/phpunit" + test_old_73_80: + runs-on: "ubuntu-latest" + name: "PHP 7.3 Code on PHP 8.0 Integration Tests" + steps: + - name: "Checkout" + uses: "actions/checkout@v2" + - name: "Install PHP" + uses: "shivammathur/setup-php@v2" + with: + coverage: "none" + php-version: "8.0" + tools: composer:v2 + - name: "Install PHP 8 dependencies" + run: "composer update --no-progress --prefer-dist" + - name: "Tests" + run: "test_old/run-php-src.sh 7.3.21" + test_old_80_70: + runs-on: "ubuntu-latest" + name: "PHP 8.0 Code on PHP 7.0 Integration Tests" + steps: + - name: "Checkout" + uses: "actions/checkout@v2" + - name: "Install PHP" + uses: "shivammathur/setup-php@v2" + with: + coverage: "none" + php-version: "7.0" + tools: composer:v2 + - name: "Install PHP 8 dependencies" + run: "composer update --no-progress --prefer-dist" + - name: "Tests" + run: "test_old/run-php-src.sh 8.0.0" diff --git a/nikic/php-parser/LICENSE b/nikic/php-parser/LICENSE index 920cc5b1f..2e5671835 100644 --- a/nikic/php-parser/LICENSE +++ b/nikic/php-parser/LICENSE @@ -1,31 +1,29 @@ -Copyright (c) 2011-2018 by Nikita Popov. +BSD 3-Clause License -Some rights reserved. +Copyright (c) 2011, Nikita Popov +All rights reserved. Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are -met: +modification, are permitted provided that the following conditions are met: - * Redistributions of source code must retain the above copyright - notice, this list of conditions and the following disclaimer. +1. Redistributions of source code must retain the above copyright notice, this + list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above - copyright notice, this list of conditions and the following - disclaimer in the documentation and/or other materials provided - with the distribution. +2. Redistributions in binary form must reproduce the above copyright notice, + this list of conditions and the following disclaimer in the documentation + and/or other materials provided with the distribution. - * The names of the contributors may not be used to endorse or - promote products derived from this software without specific - prior written permission. +3. Neither the name of the copyright holder nor the names of its + contributors may be used to endorse or promote products derived from + this software without specific prior written permission. -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" +AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE +IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE +DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE +FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL +DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR +SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER +CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, +OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/nikic/php-parser/lib/PhpParser/Builder/Param.php b/nikic/php-parser/lib/PhpParser/Builder/Param.php index fd3118c71..c6491786e 100644 --- a/nikic/php-parser/lib/PhpParser/Builder/Param.php +++ b/nikic/php-parser/lib/PhpParser/Builder/Param.php @@ -44,7 +44,7 @@ public function setDefault($value) { /** * Sets type for the parameter. * - * @param string|Node\Name|Node\NullableType $type Parameter type + * @param string|Node\Name|Node\NullableType|Node\UnionType $type Parameter type * * @return $this The builder instance (for fluid interface) */ @@ -60,7 +60,7 @@ public function setType($type) { /** * Sets type for the parameter. * - * @param string|Node\Name|Node\NullableType $type Parameter type + * @param string|Node\Name|Node\NullableType|Node\UnionType $type Parameter type * * @return $this The builder instance (for fluid interface) * diff --git a/nikic/php-parser/lib/PhpParser/BuilderHelpers.php b/nikic/php-parser/lib/PhpParser/BuilderHelpers.php index 790e8877e..180bf35d0 100644 --- a/nikic/php-parser/lib/PhpParser/BuilderHelpers.php +++ b/nikic/php-parser/lib/PhpParser/BuilderHelpers.php @@ -8,6 +8,7 @@ use PhpParser\Node\NullableType; use PhpParser\Node\Scalar; use PhpParser\Node\Stmt; +use PhpParser\Node\UnionType; /** * This class defines helpers used in the implementation of builders. Don't use it directly. @@ -158,16 +159,19 @@ private static function normalizeNameCommon($name, bool $allowExpr) { * In particular, builtin types become Identifiers, custom types become Names and nullables * are wrapped in NullableType nodes. * - * @param string|Name|Identifier|NullableType $type The type to normalize + * @param string|Name|Identifier|NullableType|UnionType $type The type to normalize * - * @return Name|Identifier|NullableType The normalized type + * @return Name|Identifier|NullableType|UnionType The normalized type */ public static function normalizeType($type) { if (!is_string($type)) { - if (!$type instanceof Name && !$type instanceof Identifier - && !$type instanceof NullableType) { + if ( + !$type instanceof Name && !$type instanceof Identifier && + !$type instanceof NullableType && !$type instanceof UnionType + ) { throw new \LogicException( - 'Type must be a string, or an instance of Name, Identifier or NullableType'); + 'Type must be a string, or an instance of Name, Identifier, NullableType or UnionType' + ); } return $type; } @@ -179,7 +183,7 @@ public static function normalizeType($type) { } $builtinTypes = [ - 'array', 'callable', 'string', 'int', 'float', 'bool', 'iterable', 'void', 'object' + 'array', 'callable', 'string', 'int', 'float', 'bool', 'iterable', 'void', 'object', 'mixed' ]; $lowerType = strtolower($type); @@ -193,7 +197,11 @@ public static function normalizeType($type) { throw new \LogicException('void type cannot be nullable'); } - return $nullable ? new Node\NullableType($type) : $type; + if ($nullable && (string) $type === 'mixed') { + throw new \LogicException('mixed type cannot be nullable'); + } + + return $nullable ? new NullableType($type) : $type; } /** diff --git a/nikic/php-parser/lib/PhpParser/Comment.php b/nikic/php-parser/lib/PhpParser/Comment.php index 5da842095..61e98d3dc 100644 --- a/nikic/php-parser/lib/PhpParser/Comment.php +++ b/nikic/php-parser/lib/PhpParser/Comment.php @@ -5,9 +5,12 @@ class Comment implements \JsonSerializable { protected $text; - protected $line; - protected $filePos; - protected $tokenPos; + protected $startLine; + protected $startFilePos; + protected $startTokenPos; + protected $endLine; + protected $endFilePos; + protected $endTokenPos; /** * Constructs a comment node. @@ -18,12 +21,17 @@ class Comment implements \JsonSerializable * @param int $startTokenPos Token offset the comment started on */ public function __construct( - string $text, int $startLine = -1, int $startFilePos = -1, int $startTokenPos = -1 + string $text, + int $startLine = -1, int $startFilePos = -1, int $startTokenPos = -1, + int $endLine = -1, int $endFilePos = -1, int $endTokenPos = -1 ) { $this->text = $text; - $this->line = $startLine; - $this->filePos = $startFilePos; - $this->tokenPos = $startTokenPos; + $this->startLine = $startLine; + $this->startFilePos = $startFilePos; + $this->startTokenPos = $startTokenPos; + $this->endLine = $endLine; + $this->endFilePos = $endFilePos; + $this->endTokenPos = $endTokenPos; } /** @@ -38,28 +46,88 @@ public function getText() : string { /** * Gets the line number the comment started on. * + * @return int Line number (or -1 if not available) + */ + public function getStartLine() : int { + return $this->startLine; + } + + /** + * Gets the file offset the comment started on. + * + * @return int File offset (or -1 if not available) + */ + public function getStartFilePos() : int { + return $this->startFilePos; + } + + /** + * Gets the token offset the comment started on. + * + * @return int Token offset (or -1 if not available) + */ + public function getStartTokenPos() : int { + return $this->startTokenPos; + } + + /** + * Gets the line number the comment ends on. + * + * @return int Line number (or -1 if not available) + */ + public function getEndLine() : int { + return $this->endLine; + } + + /** + * Gets the file offset the comment ends on. + * + * @return int File offset (or -1 if not available) + */ + public function getEndFilePos() : int { + return $this->endFilePos; + } + + /** + * Gets the token offset the comment ends on. + * + * @return int Token offset (or -1 if not available) + */ + public function getEndTokenPos() : int { + return $this->endTokenPos; + } + + /** + * Gets the line number the comment started on. + * + * @deprecated Use getStartLine() instead + * * @return int Line number */ public function getLine() : int { - return $this->line; + return $this->startLine; } /** * Gets the file offset the comment started on. * + * @deprecated Use getStartFilePos() instead + * * @return int File offset */ public function getFilePos() : int { - return $this->filePos; + return $this->startFilePos; } /** * Gets the token offset the comment started on. * + * @deprecated Use getStartTokenPos() instead + * * @return int Token offset */ public function getTokenPos() : int { - return $this->tokenPos; + return $this->startTokenPos; } /** @@ -159,9 +227,13 @@ public function jsonSerialize() : array { return [ 'nodeType' => $type, 'text' => $this->text, - 'line' => $this->line, - 'filePos' => $this->filePos, - 'tokenPos' => $this->tokenPos, + // TODO: Rename these to include "start". + 'line' => $this->startLine, + 'filePos' => $this->startFilePos, + 'tokenPos' => $this->startTokenPos, + 'endLine' => $this->endLine, + 'endFilePos' => $this->endFilePos, + 'endTokenPos' => $this->endTokenPos, ]; } } diff --git a/nikic/php-parser/lib/PhpParser/Internal/PrintableNewAnonClassNode.php b/nikic/php-parser/lib/PhpParser/Internal/PrintableNewAnonClassNode.php index 7b019db81..3eeac04a4 100644 --- a/nikic/php-parser/lib/PhpParser/Internal/PrintableNewAnonClassNode.php +++ b/nikic/php-parser/lib/PhpParser/Internal/PrintableNewAnonClassNode.php @@ -17,6 +17,8 @@ */ class PrintableNewAnonClassNode extends Expr { + /** @var Node\AttributeGroup[] PHP attribute groups */ + public $attrGroups; /** @var Node\Arg[] Arguments */ public $args; /** @var null|Node\Name Name of extended class */ @@ -27,9 +29,11 @@ class PrintableNewAnonClassNode extends Expr public $stmts; public function __construct( - array $args, Node\Name $extends = null, array $implements, array $stmts, array $attributes + array $attrGroups, array $args, Node\Name $extends = null, array $implements, + array $stmts, array $attributes ) { parent::__construct($attributes); + $this->attrGroups = $attrGroups; $this->args = $args; $this->extends = $extends; $this->implements = $implements; @@ -42,7 +46,7 @@ public static function fromNewNode(Expr\New_ $newNode) { // We don't assert that $class->name is null here, to allow consumers to assign unique names // to anonymous classes for their own purposes. We simplify ignore the name here. return new self( - $newNode->args, $class->extends, $class->implements, + $class->attrGroups, $newNode->args, $class->extends, $class->implements, $class->stmts, $newNode->getAttributes() ); } @@ -52,6 +56,6 @@ public function getType() : string { } public function getSubNodeNames() : array { - return ['args', 'extends', 'implements', 'stmts']; + return ['attrGroups', 'args', 'extends', 'implements', 'stmts']; } } diff --git a/nikic/php-parser/lib/PhpParser/Internal/TokenStream.php b/nikic/php-parser/lib/PhpParser/Internal/TokenStream.php index cf9e00abf..84c0175ec 100644 --- a/nikic/php-parser/lib/PhpParser/Internal/TokenStream.php +++ b/nikic/php-parser/lib/PhpParser/Internal/TokenStream.php @@ -33,7 +33,7 @@ public function __construct(array $tokens) { * @return bool */ public function haveParens(int $startPos, int $endPos) : bool { - return $this->haveTokenImmediativelyBefore($startPos, '(') + return $this->haveTokenImmediatelyBefore($startPos, '(') && $this->haveTokenImmediatelyAfter($endPos, ')'); } @@ -46,7 +46,8 @@ public function haveParens(int $startPos, int $endPos) : bool { * @return bool */ public function haveBraces(int $startPos, int $endPos) : bool { - return $this->haveTokenImmediativelyBefore($startPos, '{') + return ($this->haveTokenImmediatelyBefore($startPos, '{') + || $this->haveTokenImmediatelyBefore($startPos, T_CURLY_OPEN)) && $this->haveTokenImmediatelyAfter($endPos, '}'); } @@ -60,7 +61,7 @@ public function haveBraces(int $startPos, int $endPos) : bool { * * @return bool Whether the expected token was found */ - public function haveTokenImmediativelyBefore(int $pos, $expectedTokenType) : bool { + public function haveTokenImmediatelyBefore(int $pos, $expectedTokenType) : bool { $tokens = $this->tokens; $pos--; for (; $pos >= 0; $pos--) { @@ -170,7 +171,7 @@ public function skipRightWhitespace(int $pos) { return $pos; } - public function findRight($pos, $findTokenType) { + public function findRight(int $pos, $findTokenType) { $tokens = $this->tokens; for ($count = \count($tokens); $pos < $count; $pos++) { $type = $tokens[$pos][0]; @@ -181,6 +182,30 @@ public function findRight($pos, $findTokenType) { return -1; } + /** + * Whether the given position range contains a certain token type. + * + * @param int $startPos Starting position (inclusive) + * @param int $endPos Ending position (exclusive) + * @param int|string $tokenType Token type to look for + * @return bool Whether the token occurs in the given range + */ + public function haveTokenInRange(int $startPos, int $endPos, $tokenType) { + $tokens = $this->tokens; + for ($pos = $startPos; $pos < $endPos; $pos++) { + if ($tokens[$pos][0] === $tokenType) { + return true; + } + } + return false; + } + + public function haveBracesInRange(int $startPos, int $endPos) { + return $this->haveTokenInRange($startPos, $endPos, '{') + || $this->haveTokenInRange($startPos, $endPos, T_CURLY_OPEN) + || $this->haveTokenInRange($startPos, $endPos, '}'); + } + /** * Get indentation before token position. * diff --git a/nikic/php-parser/lib/PhpParser/JsonDecoder.php b/nikic/php-parser/lib/PhpParser/JsonDecoder.php index 25d1c6abe..47d2003d4 100644 --- a/nikic/php-parser/lib/PhpParser/JsonDecoder.php +++ b/nikic/php-parser/lib/PhpParser/JsonDecoder.php @@ -73,7 +73,9 @@ private function decodeComment(array $value) : Comment { } return new $className( - $value['text'], $value['line'] ?? -1, $value['filePos'] ?? -1, $value['tokenPos'] ?? -1 + $value['text'], + $value['line'] ?? -1, $value['filePos'] ?? -1, $value['tokenPos'] ?? -1, + $value['endLine'] ?? -1, $value['endFilePos'] ?? -1, $value['endTokenPos'] ?? -1 ); } diff --git a/nikic/php-parser/lib/PhpParser/Lexer.php b/nikic/php-parser/lib/PhpParser/Lexer.php index 012c1f943..832a3f4b8 100644 --- a/nikic/php-parser/lib/PhpParser/Lexer.php +++ b/nikic/php-parser/lib/PhpParser/Lexer.php @@ -15,6 +15,7 @@ class Lexer protected $tokenMap; protected $dropTokens; + protected $identifierTokens; private $attributeStartLineUsed; private $attributeEndLineUsed; @@ -34,13 +35,10 @@ class Lexer * first three. For more info see getNextToken() docs. */ public function __construct(array $options = []) { - // map from internal tokens to PhpParser tokens + // Create Map from internal tokens to PhpParser tokens. + $this->defineCompatibilityTokens(); $this->tokenMap = $this->createTokenMap(); - - // Compatibility define for PHP < 7.4 - if (!defined('T_BAD_CHARACTER')) { - \define('T_BAD_CHARACTER', -1); - } + $this->identifierTokens = $this->createIdentifierTokenMap(); // map of tokens to drop while lexing (the map is only used for isset lookup, // that's why the value is simply set to 1; the value is never actually used.) @@ -87,9 +85,8 @@ public function startLexing(string $code, ErrorHandler $errorHandler = null) { $scream = ini_set('xdebug.scream', '0'); - error_clear_last(); $this->tokens = @token_get_all($code); - $this->handleErrors($errorHandler); + $this->postprocessTokens($errorHandler); if (false !== $scream) { ini_set('xdebug.scream', $scream); @@ -131,40 +128,16 @@ private function isUnterminatedComment($token) : bool { && substr($token[1], -2) !== '*/'; } - /** - * Check whether an error *may* have occurred during tokenization. - * - * @return bool - */ - private function errorMayHaveOccurred() : bool { - if (defined('HHVM_VERSION')) { - // In HHVM token_get_all() does not throw warnings, so we need to conservatively - // assume that an error occurred - return true; - } - - if (PHP_VERSION_ID >= 80000) { - // PHP 8 converts the "bad character" case into a parse error, rather than treating - // it as a lexing warning. To preserve previous behavior, we need to assume that an - // error occurred. - // TODO: We should handle this the same way as PHP 8: Only generate T_BAD_CHARACTER - // token here (for older PHP versions) and leave generationg of the actual parse error - // to the parser. This will also save the full token scan on PHP 8 here. - return true; - } - - return null !== error_get_last(); - } - - protected function handleErrors(ErrorHandler $errorHandler) { - if (!$this->errorMayHaveOccurred()) { - return; - } - + protected function postprocessTokens(ErrorHandler $errorHandler) { // PHP's error handling for token_get_all() is rather bad, so if we want detailed // error information we need to compute it ourselves. Invalid character errors are // detected by finding "gaps" in the token array. Unterminated comments are detected // by checking if a trailing comment has a "*/" at the end. + // + // Additionally, we canonicalize to the PHP 8 comment format here, which does not include + // the trailing whitespace anymore. + // + // We also canonicalize to the PHP 8 T_NAME_* tokens. $filePos = 0; $line = 1; @@ -178,6 +151,63 @@ protected function handleErrors(ErrorHandler $errorHandler) { $this->handleInvalidCharacterRange($filePos, $filePos + 1, $line, $errorHandler); } + if ($token[0] === \T_COMMENT && substr($token[1], 0, 2) !== '/*' + && preg_match('/(\r\n|\n|\r)$/D', $token[1], $matches)) { + $trailingNewline = $matches[0]; + $token[1] = substr($token[1], 0, -strlen($trailingNewline)); + $this->tokens[$i] = $token; + if (isset($this->tokens[$i + 1]) && $this->tokens[$i + 1][0] === \T_WHITESPACE) { + // Move trailing newline into following T_WHITESPACE token, if it already exists. + $this->tokens[$i + 1][1] = $trailingNewline . $this->tokens[$i + 1][1]; + $this->tokens[$i + 1][2]--; + } else { + // Otherwise, we need to create a new T_WHITESPACE token. + array_splice($this->tokens, $i + 1, 0, [ + [\T_WHITESPACE, $trailingNewline, $line], + ]); + $numTokens++; + } + } + + // Emulate PHP 8 T_NAME_* tokens, by combining sequences of T_NS_SEPARATOR and T_STRING + // into a single token. + if (\is_array($token) + && ($token[0] === \T_NS_SEPARATOR || isset($this->identifierTokens[$token[0]]))) { + $lastWasSeparator = $token[0] === \T_NS_SEPARATOR; + $text = $token[1]; + for ($j = $i + 1; isset($this->tokens[$j]); $j++) { + if ($lastWasSeparator) { + if (!isset($this->identifierTokens[$this->tokens[$j][0]])) { + break; + } + $lastWasSeparator = false; + } else { + if ($this->tokens[$j][0] !== \T_NS_SEPARATOR) { + break; + } + $lastWasSeparator = true; + } + $text .= $this->tokens[$j][1]; + } + if ($lastWasSeparator) { + // Trailing separator is not part of the name. + $j--; + $text = substr($text, 0, -1); + } + if ($j > $i + 1) { + if ($token[0] === \T_NS_SEPARATOR) { + $type = \T_NAME_FULLY_QUALIFIED; + } else if ($token[0] === \T_NAMESPACE) { + $type = \T_NAME_RELATIVE; + } else { + $type = \T_NAME_QUALIFIED; + } + $token = [$type, $text, $line]; + array_splice($this->tokens, $i, $j - $i, [$token]); + $numTokens -= $j - $i - 1; + } + } + $tokenValue = \is_string($token) ? $token : $token[1]; $tokenLen = \strlen($tokenValue); @@ -300,17 +330,23 @@ public function getNextToken(&$value = null, &$startAttributes = null, &$endAttr $this->line += substr_count($value, "\n"); $this->filePos += \strlen($value); } else { + $origLine = $this->line; + $origFilePos = $this->filePos; + $this->line += substr_count($token[1], "\n"); + $this->filePos += \strlen($token[1]); + if (\T_COMMENT === $token[0] || \T_DOC_COMMENT === $token[0]) { if ($this->attributeCommentsUsed) { $comment = \T_DOC_COMMENT === $token[0] - ? new Comment\Doc($token[1], $this->line, $this->filePos, $this->pos) - : new Comment($token[1], $this->line, $this->filePos, $this->pos); + ? new Comment\Doc($token[1], + $origLine, $origFilePos, $this->pos, + $this->line, $this->filePos - 1, $this->pos) + : new Comment($token[1], + $origLine, $origFilePos, $this->pos, + $this->line, $this->filePos - 1, $this->pos); $startAttributes['comments'][] = $comment; } } - - $this->line += substr_count($token[1], "\n"); - $this->filePos += \strlen($token[1]); continue; } @@ -367,6 +403,61 @@ public function handleHaltCompiler() : string { return substr($textAfter, strlen($matches[0])); } + private function defineCompatibilityTokens() { + static $compatTokensDefined = false; + if ($compatTokensDefined) { + return; + } + + $compatTokens = [ + // PHP 7.4 + 'T_BAD_CHARACTER', + 'T_FN', + 'T_COALESCE_EQUAL', + // PHP 8.0 + 'T_NAME_QUALIFIED', + 'T_NAME_FULLY_QUALIFIED', + 'T_NAME_RELATIVE', + 'T_MATCH', + 'T_NULLSAFE_OBJECT_OPERATOR', + 'T_ATTRIBUTE', + ]; + + // PHP-Parser might be used together with another library that also emulates some or all + // of these tokens. Perform a sanity-check that all already defined tokens have been + // assigned a unique ID. + $usedTokenIds = []; + foreach ($compatTokens as $token) { + if (\defined($token)) { + $tokenId = \constant($token); + $clashingToken = $usedTokenIds[$tokenId] ?? null; + if ($clashingToken !== null) { + throw new \Error(sprintf( + 'Token %s has same ID as token %s, ' . + 'you may be using a library with broken token emulation', + $token, $clashingToken + )); + } + $usedTokenIds[$tokenId] = $token; + } + } + + // Now define any tokens that have not yet been emulated. Try to assign IDs from -1 + // downwards, but skip any IDs that may already be in use. + $newTokenId = -1; + foreach ($compatTokens as $token) { + if (!\defined($token)) { + while (isset($usedTokenIds[$newTokenId])) { + $newTokenId--; + } + \define($token, $newTokenId); + $newTokenId--; + } + } + + $compatTokensDefined = true; + } + /** * Creates the token map. * @@ -411,6 +502,32 @@ protected function createTokenMap() : array { $tokenMap[\T_COMPILER_HALT_OFFSET] = Tokens::T_STRING; } + // Assign tokens for which we define compatibility constants, as token_name() does not know them. + $tokenMap[\T_FN] = Tokens::T_FN; + $tokenMap[\T_COALESCE_EQUAL] = Tokens::T_COALESCE_EQUAL; + $tokenMap[\T_NAME_QUALIFIED] = Tokens::T_NAME_QUALIFIED; + $tokenMap[\T_NAME_FULLY_QUALIFIED] = Tokens::T_NAME_FULLY_QUALIFIED; + $tokenMap[\T_NAME_RELATIVE] = Tokens::T_NAME_RELATIVE; + $tokenMap[\T_MATCH] = Tokens::T_MATCH; + $tokenMap[\T_NULLSAFE_OBJECT_OPERATOR] = Tokens::T_NULLSAFE_OBJECT_OPERATOR; + $tokenMap[\T_ATTRIBUTE] = Tokens::T_ATTRIBUTE; + return $tokenMap; } + + private function createIdentifierTokenMap(): array { + // Based on semi_reserved production. + return array_fill_keys([ + \T_STRING, + \T_STATIC, \T_ABSTRACT, \T_FINAL, \T_PRIVATE, \T_PROTECTED, \T_PUBLIC, + \T_INCLUDE, \T_INCLUDE_ONCE, \T_EVAL, \T_REQUIRE, \T_REQUIRE_ONCE, \T_LOGICAL_OR, \T_LOGICAL_XOR, \T_LOGICAL_AND, + \T_INSTANCEOF, \T_NEW, \T_CLONE, \T_EXIT, \T_IF, \T_ELSEIF, \T_ELSE, \T_ENDIF, \T_ECHO, \T_DO, \T_WHILE, + \T_ENDWHILE, \T_FOR, \T_ENDFOR, \T_FOREACH, \T_ENDFOREACH, \T_DECLARE, \T_ENDDECLARE, \T_AS, \T_TRY, \T_CATCH, + \T_FINALLY, \T_THROW, \T_USE, \T_INSTEADOF, \T_GLOBAL, \T_VAR, \T_UNSET, \T_ISSET, \T_EMPTY, \T_CONTINUE, \T_GOTO, + \T_FUNCTION, \T_CONST, \T_RETURN, \T_PRINT, \T_YIELD, \T_LIST, \T_SWITCH, \T_ENDSWITCH, \T_CASE, \T_DEFAULT, + \T_BREAK, \T_ARRAY, \T_CALLABLE, \T_EXTENDS, \T_IMPLEMENTS, \T_NAMESPACE, \T_TRAIT, \T_INTERFACE, \T_CLASS, + \T_CLASS_C, \T_TRAIT_C, \T_FUNC_C, \T_METHOD_C, \T_LINE, \T_FILE, \T_DIR, \T_NS_C, \T_HALT_COMPILER, \T_FN, + \T_MATCH, + ], true); + } } diff --git a/nikic/php-parser/lib/PhpParser/Lexer/Emulative.php b/nikic/php-parser/lib/PhpParser/Lexer/Emulative.php index 0e1454172..cf1f8e5a9 100644 --- a/nikic/php-parser/lib/PhpParser/Lexer/Emulative.php +++ b/nikic/php-parser/lib/PhpParser/Lexer/Emulative.php @@ -5,61 +5,85 @@ use PhpParser\Error; use PhpParser\ErrorHandler; use PhpParser\Lexer; +use PhpParser\Lexer\TokenEmulator\AttributeEmulator; use PhpParser\Lexer\TokenEmulator\CoaleseEqualTokenEmulator; +use PhpParser\Lexer\TokenEmulator\FlexibleDocStringEmulator; use PhpParser\Lexer\TokenEmulator\FnTokenEmulator; +use PhpParser\Lexer\TokenEmulator\MatchTokenEmulator; +use PhpParser\Lexer\TokenEmulator\NullsafeTokenEmulator; use PhpParser\Lexer\TokenEmulator\NumericLiteralSeparatorEmulator; -use PhpParser\Lexer\TokenEmulator\TokenEmulatorInterface; +use PhpParser\Lexer\TokenEmulator\ReverseEmulator; +use PhpParser\Lexer\TokenEmulator\TokenEmulator; use PhpParser\Parser\Tokens; class Emulative extends Lexer { - const PHP_7_3 = '7.3.0dev'; - const PHP_7_4 = '7.4.0dev'; - - const T_COALESCE_EQUAL = 1007; - const T_FN = 1008; - - const FLEXIBLE_DOC_STRING_REGEX = <<<'REGEX' -/<<<[ \t]*(['"]?)([a-zA-Z_\x80-\xff][a-zA-Z0-9_\x80-\xff]*)\1\r?\n -(?:.*\r?\n)*? -(?\h*)\2(?![a-zA-Z0-9_\x80-\xff])(?(?:;?[\r\n])?)/x -REGEX; + const PHP_7_3 = '7.3dev'; + const PHP_7_4 = '7.4dev'; + const PHP_8_0 = '8.0dev'; /** @var mixed[] Patches used to reverse changes introduced in the code */ private $patches = []; - /** @var TokenEmulatorInterface[] */ - private $tokenEmulators = []; + /** @var TokenEmulator[] */ + private $emulators = []; + + /** @var string */ + private $targetPhpVersion; /** - * @param mixed[] $options + * @param mixed[] $options Lexer options. In addition to the usual options, + * accepts a 'phpVersion' string that specifies the + * version to emulated. Defaults to newest supported. */ public function __construct(array $options = []) { - parent::__construct($options); + $this->targetPhpVersion = $options['phpVersion'] ?? Emulative::PHP_8_0; + unset($options['phpVersion']); - $this->tokenEmulators[] = new FnTokenEmulator(); - $this->tokenEmulators[] = new CoaleseEqualTokenEmulator(); - $this->tokenEmulators[] = new NumericLiteralSeparatorEmulator(); + parent::__construct($options); - $this->tokenMap[self::T_COALESCE_EQUAL] = Tokens::T_COALESCE_EQUAL; - $this->tokenMap[self::T_FN] = Tokens::T_FN; + $emulators = [ + new FlexibleDocStringEmulator(), + new FnTokenEmulator(), + new MatchTokenEmulator(), + new CoaleseEqualTokenEmulator(), + new NumericLiteralSeparatorEmulator(), + new NullsafeTokenEmulator(), + new AttributeEmulator(), + ]; + + // Collect emulators that are relevant for the PHP version we're running + // and the PHP version we're targeting for emulation. + foreach ($emulators as $emulator) { + $emulatorPhpVersion = $emulator->getPhpVersion(); + if ($this->isForwardEmulationNeeded($emulatorPhpVersion)) { + $this->emulators[] = $emulator; + } else if ($this->isReverseEmulationNeeded($emulatorPhpVersion)) { + $this->emulators[] = new ReverseEmulator($emulator); + } + } } public function startLexing(string $code, ErrorHandler $errorHandler = null) { - $this->patches = []; + $emulators = array_filter($this->emulators, function($emulator) use($code) { + return $emulator->isEmulationNeeded($code); + }); - if ($this->isEmulationNeeded($code) === false) { + if (empty($emulators)) { // Nothing to emulate, yay parent::startLexing($code, $errorHandler); return; } - $collector = new ErrorHandler\Collecting(); + $this->patches = []; + foreach ($emulators as $emulator) { + $code = $emulator->preprocessCode($code, $this->patches); + } - // 1. emulation of heredoc and nowdoc new syntax - $preparedCode = $this->processHeredocNowdoc($code); - parent::startLexing($preparedCode, $collector); + $collector = new ErrorHandler\Collecting(); + parent::startLexing($code, $collector); + $this->sortPatches(); $this->fixupTokens(); $errors = $collector->getErrors(); @@ -70,78 +94,28 @@ public function startLexing(string $code, ErrorHandler $errorHandler = null) { } } - // add token emulation - foreach ($this->tokenEmulators as $emulativeToken) { - if ($emulativeToken->isEmulationNeeded($code)) { - $this->tokens = $emulativeToken->emulate($code, $this->tokens); - } + foreach ($emulators as $emulator) { + $this->tokens = $emulator->emulate($code, $this->tokens); } } - private function isHeredocNowdocEmulationNeeded(string $code): bool - { - // skip version where this works without emulation - if (version_compare(\PHP_VERSION, self::PHP_7_3, '>=')) { - return false; - } - - return strpos($code, '<<<') !== false; + private function isForwardEmulationNeeded(string $emulatorPhpVersion): bool { + return version_compare(\PHP_VERSION, $emulatorPhpVersion, '<') + && version_compare($this->targetPhpVersion, $emulatorPhpVersion, '>='); } - private function processHeredocNowdoc(string $code): string - { - if ($this->isHeredocNowdocEmulationNeeded($code) === false) { - return $code; - } - - if (!preg_match_all(self::FLEXIBLE_DOC_STRING_REGEX, $code, $matches, PREG_SET_ORDER|PREG_OFFSET_CAPTURE)) { - // No heredoc/nowdoc found - return $code; - } - - // Keep track of how much we need to adjust string offsets due to the modifications we - // already made - $posDelta = 0; - foreach ($matches as $match) { - $indentation = $match['indentation'][0]; - $indentationStart = $match['indentation'][1]; - - $separator = $match['separator'][0]; - $separatorStart = $match['separator'][1]; - - if ($indentation === '' && $separator !== '') { - // Ordinary heredoc/nowdoc - continue; - } - - if ($indentation !== '') { - // Remove indentation - $indentationLen = strlen($indentation); - $code = substr_replace($code, '', $indentationStart + $posDelta, $indentationLen); - $this->patches[] = [$indentationStart + $posDelta, 'add', $indentation]; - $posDelta -= $indentationLen; - } - - if ($separator === '') { - // Insert newline as separator - $code = substr_replace($code, "\n", $separatorStart + $posDelta, 0); - $this->patches[] = [$separatorStart + $posDelta, 'remove', "\n"]; - $posDelta += 1; - } - } - - return $code; + private function isReverseEmulationNeeded(string $emulatorPhpVersion): bool { + return version_compare(\PHP_VERSION, $emulatorPhpVersion, '>=') + && version_compare($this->targetPhpVersion, $emulatorPhpVersion, '<'); } - private function isEmulationNeeded(string $code): bool + private function sortPatches() { - foreach ($this->tokenEmulators as $emulativeToken) { - if ($emulativeToken->isEmulationNeeded($code)) { - return true; - } - } - - return $this->isHeredocNowdocEmulationNeeded($code); + // Patches may be contributed by different emulators. + // Make sure they are sorted by increasing patch position. + usort($this->patches, function($p1, $p2) { + return $p1[0] <=> $p2[0]; + }); } private function fixupTokens() @@ -160,7 +134,20 @@ private function fixupTokens() for ($i = 0, $c = \count($this->tokens); $i < $c; $i++) { $token = $this->tokens[$i]; if (\is_string($token)) { - // We assume that patches don't apply to string tokens + if ($patchPos === $pos) { + // Only support replacement for string tokens. + assert($patchType === 'replace'); + $this->tokens[$i] = $patchText; + + // Fetch the next patch + $patchIdx++; + if ($patchIdx >= \count($this->patches)) { + // No more patches, we're done + return; + } + list($patchPos, $patchType, $patchText) = $this->patches[$patchIdx]; + } + $pos += \strlen($token); continue; } @@ -188,6 +175,11 @@ private function fixupTokens() $token[1], $patchText, $patchPos - $pos + $posDelta, 0 ); $posDelta += $patchTextLen; + } else if ($patchType === 'replace') { + // Replace inside the token string + $this->tokens[$i][1] = substr_replace( + $token[1], $patchText, $patchPos - $pos + $posDelta, $patchTextLen + ); } else { assert(false); } @@ -234,7 +226,7 @@ private function fixupErrors(array $errors) { if ($patchType === 'add') { $posDelta += strlen($patchText); $lineDelta += substr_count($patchText, "\n"); - } else { + } else if ($patchType === 'remove') { $posDelta -= strlen($patchText); $lineDelta -= substr_count($patchText, "\n"); } diff --git a/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/AttributeEmulator.php b/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/AttributeEmulator.php new file mode 100644 index 000000000..6776a5197 --- /dev/null +++ b/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/AttributeEmulator.php @@ -0,0 +1,56 @@ +=')) { - return false; - } + return Emulative::PHP_7_4; + } + public function isEmulationNeeded(string $code): bool + { return strpos($code, '??=') !== false; } @@ -25,7 +25,7 @@ public function emulate(string $code, array $tokens): array if (isset($tokens[$i + 1])) { if ($tokens[$i][0] === T_COALESCE && $tokens[$i + 1] === '=') { array_splice($tokens, $i, 2, [ - [Emulative::T_COALESCE_EQUAL, '??=', $line] + [\T_COALESCE_EQUAL, '??=', $line] ]); $c--; continue; @@ -38,4 +38,10 @@ public function emulate(string $code, array $tokens): array return $tokens; } + + public function reverseEmulate(string $code, array $tokens): array + { + // ??= was not valid code previously, don't bother. + return $tokens; + } } diff --git a/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/FlexibleDocStringEmulator.php b/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/FlexibleDocStringEmulator.php new file mode 100644 index 000000000..c15d6271f --- /dev/null +++ b/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/FlexibleDocStringEmulator.php @@ -0,0 +1,76 @@ +\h*)\2(?![a-zA-Z0-9_\x80-\xff])(?(?:;?[\r\n])?)/x +REGEX; + + public function getPhpVersion(): string + { + return Emulative::PHP_7_3; + } + + public function isEmulationNeeded(string $code) : bool + { + return strpos($code, '<<<') !== false; + } + + public function emulate(string $code, array $tokens): array + { + // Handled by preprocessing + fixup. + return $tokens; + } + + public function reverseEmulate(string $code, array $tokens): array + { + // Not supported. + return $tokens; + } + + public function preprocessCode(string $code, array &$patches): string { + if (!preg_match_all(self::FLEXIBLE_DOC_STRING_REGEX, $code, $matches, PREG_SET_ORDER|PREG_OFFSET_CAPTURE)) { + // No heredoc/nowdoc found + return $code; + } + + // Keep track of how much we need to adjust string offsets due to the modifications we + // already made + $posDelta = 0; + foreach ($matches as $match) { + $indentation = $match['indentation'][0]; + $indentationStart = $match['indentation'][1]; + + $separator = $match['separator'][0]; + $separatorStart = $match['separator'][1]; + + if ($indentation === '' && $separator !== '') { + // Ordinary heredoc/nowdoc + continue; + } + + if ($indentation !== '') { + // Remove indentation + $indentationLen = strlen($indentation); + $code = substr_replace($code, '', $indentationStart + $posDelta, $indentationLen); + $patches[] = [$indentationStart + $posDelta, 'add', $indentation]; + $posDelta -= $indentationLen; + } + + if ($separator === '') { + // Insert newline as separator + $code = substr_replace($code, "\n", $separatorStart + $posDelta, 0); + $patches[] = [$separatorStart + $posDelta, 'remove', "\n"]; + $posDelta += 1; + } + } + + return $code; + } +} diff --git a/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/FnTokenEmulator.php b/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/FnTokenEmulator.php index 0939dd46c..eb7e49634 100644 --- a/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/FnTokenEmulator.php +++ b/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/FnTokenEmulator.php @@ -4,50 +4,20 @@ use PhpParser\Lexer\Emulative; -final class FnTokenEmulator implements TokenEmulatorInterface +final class FnTokenEmulator extends KeywordEmulator { - public function isEmulationNeeded(string $code) : bool + public function getPhpVersion(): string { - // skip version where this is supported - if (version_compare(\PHP_VERSION, Emulative::PHP_7_4, '>=')) { - return false; - } - - return strpos($code, 'fn') !== false; + return Emulative::PHP_7_4; } - public function emulate(string $code, array $tokens): array + public function getKeywordString(): string { - // We need to manually iterate and manage a count because we'll change - // the tokens array on the way - foreach ($tokens as $i => $token) { - if ($token[0] === T_STRING && $token[1] === 'fn') { - $previousNonSpaceToken = $this->getPreviousNonSpaceToken($tokens, $i); - if ($previousNonSpaceToken !== null && $previousNonSpaceToken[0] === T_OBJECT_OPERATOR) { - continue; - } - - $tokens[$i][0] = Emulative::T_FN; - } - } - - return $tokens; + return 'fn'; } - /** - * @param mixed[] $tokens - * @return mixed[]|null - */ - private function getPreviousNonSpaceToken(array $tokens, int $start) + public function getKeywordToken(): int { - for ($i = $start - 1; $i >= 0; --$i) { - if ($tokens[$i][0] === T_WHITESPACE) { - continue; - } - - return $tokens[$i]; - } - - return null; + return \T_FN; } -} +} \ No newline at end of file diff --git a/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/KeywordEmulator.php b/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/KeywordEmulator.php new file mode 100644 index 000000000..e7c0512bd --- /dev/null +++ b/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/KeywordEmulator.php @@ -0,0 +1,60 @@ +getKeywordString()) !== false; + } + + public function emulate(string $code, array $tokens): array + { + $keywordString = $this->getKeywordString(); + foreach ($tokens as $i => $token) { + if ($token[0] === T_STRING && strtolower($token[1]) === $keywordString) { + $previousNonSpaceToken = $this->getPreviousNonSpaceToken($tokens, $i); + if ($previousNonSpaceToken !== null && $previousNonSpaceToken[0] === \T_OBJECT_OPERATOR) { + continue; + } + + $tokens[$i][0] = $this->getKeywordToken(); + } + } + + return $tokens; + } + + /** + * @param mixed[] $tokens + * @return mixed[]|null + */ + private function getPreviousNonSpaceToken(array $tokens, int $start) + { + for ($i = $start - 1; $i >= 0; --$i) { + if ($tokens[$i][0] === T_WHITESPACE) { + continue; + } + + return $tokens[$i]; + } + + return null; + } + + public function reverseEmulate(string $code, array $tokens): array + { + $keywordToken = $this->getKeywordToken(); + foreach ($tokens as $i => $token) { + if ($token[0] === $keywordToken) { + $tokens[$i][0] = \T_STRING; + } + } + + return $tokens; + } +} diff --git a/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/MatchTokenEmulator.php b/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/MatchTokenEmulator.php new file mode 100644 index 000000000..902a46dfc --- /dev/null +++ b/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/MatchTokenEmulator.php @@ -0,0 +1,23 @@ +') !== false; + } + + public function emulate(string $code, array $tokens): array + { + // We need to manually iterate and manage a count because we'll change + // the tokens array on the way + $line = 1; + for ($i = 0, $c = count($tokens); $i < $c; ++$i) { + if ($tokens[$i] === '?' && isset($tokens[$i + 1]) && $tokens[$i + 1][0] === \T_OBJECT_OPERATOR) { + array_splice($tokens, $i, 2, [ + [\T_NULLSAFE_OBJECT_OPERATOR, '?->', $line] + ]); + $c--; + continue; + } + + // Handle ?-> inside encapsed string. + if ($tokens[$i][0] === \T_ENCAPSED_AND_WHITESPACE && isset($tokens[$i - 1]) + && $tokens[$i - 1][0] === \T_VARIABLE + && preg_match('/^\?->([a-zA-Z_\x80-\xff][a-zA-Z0-9_\x80-\xff]*)/', $tokens[$i][1], $matches) + ) { + $replacement = [ + [\T_NULLSAFE_OBJECT_OPERATOR, '?->', $line], + [\T_STRING, $matches[1], $line], + ]; + if (\strlen($matches[0]) !== \strlen($tokens[$i][1])) { + $replacement[] = [ + \T_ENCAPSED_AND_WHITESPACE, + \substr($tokens[$i][1], \strlen($matches[0])), + $line + ]; + } + array_splice($tokens, $i, 1, $replacement); + $c += \count($replacement) - 1; + continue; + } + + if (\is_array($tokens[$i])) { + $line += substr_count($tokens[$i][1], "\n"); + } + } + + return $tokens; + } + + public function reverseEmulate(string $code, array $tokens): array + { + // ?-> was not valid code previously, don't bother. + return $tokens; + } +} diff --git a/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/NumericLiteralSeparatorEmulator.php b/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/NumericLiteralSeparatorEmulator.php index f564c5941..cdf793e46 100644 --- a/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/NumericLiteralSeparatorEmulator.php +++ b/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/NumericLiteralSeparatorEmulator.php @@ -4,7 +4,7 @@ use PhpParser\Lexer\Emulative; -final class NumericLiteralSeparatorEmulator implements TokenEmulatorInterface +final class NumericLiteralSeparatorEmulator extends TokenEmulator { const BIN = '(?:0b[01]+(?:_[01]+)*)'; const HEX = '(?:0x[0-9a-f]+(?:_[0-9a-f]+)*)'; @@ -14,14 +14,15 @@ final class NumericLiteralSeparatorEmulator implements TokenEmulatorInterface const FLOAT = '(?:' . self::SIMPLE_FLOAT . self::EXP . '?|' . self::DEC . self::EXP . ')'; const NUMBER = '~' . self::FLOAT . '|' . self::BIN . '|' . self::HEX . '|' . self::DEC . '~iA'; - public function isEmulationNeeded(string $code) : bool + public function getPhpVersion(): string { - // skip version where this is supported - if (version_compare(\PHP_VERSION, Emulative::PHP_7_4, '>=')) { - return false; - } + return Emulative::PHP_7_4; + } - return preg_match('~[0-9a-f]_[0-9a-f]~i', $code) !== false; + public function isEmulationNeeded(string $code) : bool + { + return preg_match('~[0-9]_[0-9]~', $code) + || preg_match('~0x[0-9a-f]+_[0-9a-f]~i', $code); } public function emulate(string $code, array $tokens): array @@ -95,4 +96,10 @@ private function resolveIntegerOrFloatToken(string $str): int return is_float($num) ? T_DNUMBER : T_LNUMBER; } + + public function reverseEmulate(string $code, array $tokens): array + { + // Numeric separators were not legal code previously, don't bother. + return $tokens; + } } diff --git a/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/ReverseEmulator.php b/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/ReverseEmulator.php new file mode 100644 index 000000000..90093f66b --- /dev/null +++ b/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/ReverseEmulator.php @@ -0,0 +1,36 @@ +emulator = $emulator; + } + + public function getPhpVersion(): string { + return $this->emulator->getPhpVersion(); + } + + public function isEmulationNeeded(string $code): bool { + return $this->emulator->isEmulationNeeded($code); + } + + public function emulate(string $code, array $tokens): array { + return $this->emulator->reverseEmulate($code, $tokens); + } + + public function reverseEmulate(string $code, array $tokens): array { + return $this->emulator->emulate($code, $tokens); + } + + public function preprocessCode(string $code, array &$patches): string { + return $code; + } +} \ No newline at end of file diff --git a/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/TokenEmulator.php b/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/TokenEmulator.php new file mode 100644 index 000000000..a020bc0ff --- /dev/null +++ b/nikic/php-parser/lib/PhpParser/Lexer/TokenEmulator/TokenEmulator.php @@ -0,0 +1,25 @@ +attributes = $attributes; + $this->name = $name; $this->value = $value; $this->byRef = $byRef; $this->unpack = $unpack; } public function getSubNodeNames() : array { - return ['value', 'byRef', 'unpack']; + return ['name', 'value', 'byRef', 'unpack']; } public function getType() : string { diff --git a/nikic/php-parser/lib/PhpParser/Node/Attribute.php b/nikic/php-parser/lib/PhpParser/Node/Attribute.php new file mode 100644 index 000000000..c96f66e51 --- /dev/null +++ b/nikic/php-parser/lib/PhpParser/Node/Attribute.php @@ -0,0 +1,34 @@ +attributes = $attributes; + $this->name = $name; + $this->args = $args; + } + + public function getSubNodeNames() : array { + return ['name', 'args']; + } + + public function getType() : string { + return 'Attribute'; + } +} diff --git a/nikic/php-parser/lib/PhpParser/Node/AttributeGroup.php b/nikic/php-parser/lib/PhpParser/Node/AttributeGroup.php new file mode 100644 index 000000000..613bfc413 --- /dev/null +++ b/nikic/php-parser/lib/PhpParser/Node/AttributeGroup.php @@ -0,0 +1,29 @@ +attributes = $attributes; + $this->attrs = $attrs; + } + + public function getSubNodeNames() : array { + return ['attrs']; + } + + public function getType() : string { + return 'AttributeGroup'; + } +} diff --git a/nikic/php-parser/lib/PhpParser/Node/Const_.php b/nikic/php-parser/lib/PhpParser/Node/Const_.php index 4094a653d..789a42655 100644 --- a/nikic/php-parser/lib/PhpParser/Node/Const_.php +++ b/nikic/php-parser/lib/PhpParser/Node/Const_.php @@ -5,7 +5,7 @@ use PhpParser\NodeAbstract; /** - * @property Name $namespacedName Namespaced name (for class constants, if using NameResolver) + * @property Name $namespacedName Namespaced name (for global constants, if using NameResolver) */ class Const_ extends NodeAbstract { diff --git a/nikic/php-parser/lib/PhpParser/Node/Expr/Array_.php b/nikic/php-parser/lib/PhpParser/Node/Expr/Array_.php index fbe207ee3..e6eaa2834 100644 --- a/nikic/php-parser/lib/PhpParser/Node/Expr/Array_.php +++ b/nikic/php-parser/lib/PhpParser/Node/Expr/Array_.php @@ -10,13 +10,13 @@ class Array_ extends Expr const KIND_LONG = 1; // array() syntax const KIND_SHORT = 2; // [] syntax - /** @var ArrayItem[] Items */ + /** @var (ArrayItem|null)[] Items */ public $items; /** * Constructs an array node. * - * @param ArrayItem[] $items Items of the array + * @param (ArrayItem|null)[] $items Items of the array * @param array $attributes Additional attributes */ public function __construct(array $items = [], array $attributes = []) { diff --git a/nikic/php-parser/lib/PhpParser/Node/Expr/ArrowFunction.php b/nikic/php-parser/lib/PhpParser/Node/Expr/ArrowFunction.php index 608055f40..d293f0ae4 100644 --- a/nikic/php-parser/lib/PhpParser/Node/Expr/ArrowFunction.php +++ b/nikic/php-parser/lib/PhpParser/Node/Expr/ArrowFunction.php @@ -22,6 +22,8 @@ class ArrowFunction extends Expr implements FunctionLike /** @var Expr */ public $expr; + /** @var Node\AttributeGroup[] */ + public $attrGroups; /** * @param array $subNodes Array of the following optional subnodes: @@ -30,6 +32,7 @@ class ArrowFunction extends Expr implements FunctionLike * 'params' => array() : Parameters * 'returnType' => null : Return type * 'expr' => Expr : Expression body + * 'attrGroups' => array() : PHP attribute groups * @param array $attributes Additional attributes */ public function __construct(array $subNodes = [], array $attributes = []) { @@ -40,10 +43,11 @@ public function __construct(array $subNodes = [], array $attributes = []) { $returnType = $subNodes['returnType'] ?? null; $this->returnType = \is_string($returnType) ? new Node\Identifier($returnType) : $returnType; $this->expr = $subNodes['expr'] ?? null; + $this->attrGroups = $subNodes['attrGroups'] ?? []; } public function getSubNodeNames() : array { - return ['static', 'byRef', 'params', 'returnType', 'expr']; + return ['attrGroups', 'static', 'byRef', 'params', 'returnType', 'expr']; } public function returnsByRef() : bool { @@ -58,6 +62,10 @@ public function getReturnType() { return $this->returnType; } + public function getAttrGroups() : array { + return $this->attrGroups; + } + /** * @return Node\Stmt\Return_[] */ diff --git a/nikic/php-parser/lib/PhpParser/Node/Expr/Closure.php b/nikic/php-parser/lib/PhpParser/Node/Expr/Closure.php index 9a5fee226..56e621f25 100644 --- a/nikic/php-parser/lib/PhpParser/Node/Expr/Closure.php +++ b/nikic/php-parser/lib/PhpParser/Node/Expr/Closure.php @@ -20,6 +20,8 @@ class Closure extends Expr implements FunctionLike public $returnType; /** @var Node\Stmt[] Statements */ public $stmts; + /** @var Node\AttributeGroup[] PHP attribute groups */ + public $attrGroups; /** * Constructs a lambda function node. @@ -31,6 +33,7 @@ class Closure extends Expr implements FunctionLike * 'uses' => array(): use()s * 'returnType' => null : Return type * 'stmts' => array(): Statements + * 'attrGroups' => array(): PHP attributes groups * @param array $attributes Additional attributes */ public function __construct(array $subNodes = [], array $attributes = []) { @@ -42,10 +45,11 @@ public function __construct(array $subNodes = [], array $attributes = []) { $returnType = $subNodes['returnType'] ?? null; $this->returnType = \is_string($returnType) ? new Node\Identifier($returnType) : $returnType; $this->stmts = $subNodes['stmts'] ?? []; + $this->attrGroups = $subNodes['attrGroups'] ?? []; } public function getSubNodeNames() : array { - return ['static', 'byRef', 'params', 'uses', 'returnType', 'stmts']; + return ['attrGroups', 'static', 'byRef', 'params', 'uses', 'returnType', 'stmts']; } public function returnsByRef() : bool { @@ -64,7 +68,11 @@ public function getReturnType() { public function getStmts() : array { return $this->stmts; } - + + public function getAttrGroups() : array { + return $this->attrGroups; + } + public function getType() : string { return 'Expr_Closure'; } diff --git a/nikic/php-parser/lib/PhpParser/Node/Expr/Match_.php b/nikic/php-parser/lib/PhpParser/Node/Expr/Match_.php new file mode 100644 index 000000000..2455a3026 --- /dev/null +++ b/nikic/php-parser/lib/PhpParser/Node/Expr/Match_.php @@ -0,0 +1,31 @@ +attributes = $attributes; + $this->cond = $cond; + $this->arms = $arms; + } + + public function getSubNodeNames() : array { + return ['cond', 'arms']; + } + + public function getType() : string { + return 'Expr_Match'; + } +} diff --git a/nikic/php-parser/lib/PhpParser/Node/Expr/NullsafeMethodCall.php b/nikic/php-parser/lib/PhpParser/Node/Expr/NullsafeMethodCall.php new file mode 100644 index 000000000..361e44622 --- /dev/null +++ b/nikic/php-parser/lib/PhpParser/Node/Expr/NullsafeMethodCall.php @@ -0,0 +1,40 @@ +attributes = $attributes; + $this->var = $var; + $this->name = \is_string($name) ? new Identifier($name) : $name; + $this->args = $args; + } + + public function getSubNodeNames() : array { + return ['var', 'name', 'args']; + } + + public function getType() : string { + return 'Expr_NullsafeMethodCall'; + } +} diff --git a/nikic/php-parser/lib/PhpParser/Node/Expr/NullsafePropertyFetch.php b/nikic/php-parser/lib/PhpParser/Node/Expr/NullsafePropertyFetch.php new file mode 100644 index 000000000..9317eb3b9 --- /dev/null +++ b/nikic/php-parser/lib/PhpParser/Node/Expr/NullsafePropertyFetch.php @@ -0,0 +1,35 @@ +attributes = $attributes; + $this->var = $var; + $this->name = \is_string($name) ? new Identifier($name) : $name; + } + + public function getSubNodeNames() : array { + return ['var', 'name']; + } + + public function getType() : string { + return 'Expr_NullsafePropertyFetch'; + } +} diff --git a/nikic/php-parser/lib/PhpParser/Node/Expr/Throw_.php b/nikic/php-parser/lib/PhpParser/Node/Expr/Throw_.php new file mode 100644 index 000000000..5c97f0e2b --- /dev/null +++ b/nikic/php-parser/lib/PhpParser/Node/Expr/Throw_.php @@ -0,0 +1,30 @@ +attributes = $attributes; + $this->expr = $expr; + } + + public function getSubNodeNames() : array { + return ['expr']; + } + + public function getType() : string { + return 'Expr_Throw'; + } +} diff --git a/nikic/php-parser/lib/PhpParser/Node/FunctionLike.php b/nikic/php-parser/lib/PhpParser/Node/FunctionLike.php index 110da6e96..bbcf53e55 100644 --- a/nikic/php-parser/lib/PhpParser/Node/FunctionLike.php +++ b/nikic/php-parser/lib/PhpParser/Node/FunctionLike.php @@ -16,21 +16,28 @@ public function returnsByRef() : bool; /** * List of parameters * - * @return Node\Param[] + * @return Param[] */ public function getParams() : array; /** * Get the declared return type or null * - * @return null|Identifier|Node\Name|Node\NullableType|Node\UnionType + * @return null|Identifier|Name|NullableType|UnionType */ public function getReturnType(); /** * The function body * - * @return Node\Stmt[]|null + * @return Stmt[]|null */ public function getStmts(); + + /** + * Get PHP attribute groups. + * + * @return AttributeGroup[] + */ + public function getAttrGroups() : array; } diff --git a/nikic/php-parser/lib/PhpParser/Node/MatchArm.php b/nikic/php-parser/lib/PhpParser/Node/MatchArm.php new file mode 100644 index 000000000..2ae1c86b8 --- /dev/null +++ b/nikic/php-parser/lib/PhpParser/Node/MatchArm.php @@ -0,0 +1,31 @@ +conds = $conds; + $this->body = $body; + $this->attributes = $attributes; + } + + public function getSubNodeNames() : array { + return ['conds', 'body']; + } + + public function getType() : string { + return 'MatchArm'; + } +} diff --git a/nikic/php-parser/lib/PhpParser/Node/Name.php b/nikic/php-parser/lib/PhpParser/Node/Name.php index 7ebdd579c..6b1cc9f8e 100644 --- a/nikic/php-parser/lib/PhpParser/Node/Name.php +++ b/nikic/php-parser/lib/PhpParser/Node/Name.php @@ -85,7 +85,7 @@ public function isRelative() : bool { } /** - * Returns a string representation of the name itself, without taking taking the name type into + * Returns a string representation of the name itself, without taking the name type into * account (e.g., not including a leading backslash for fully qualified names). * * @return string String representation diff --git a/nikic/php-parser/lib/PhpParser/Node/Param.php b/nikic/php-parser/lib/PhpParser/Node/Param.php index 76db7180f..315b5f24f 100644 --- a/nikic/php-parser/lib/PhpParser/Node/Param.php +++ b/nikic/php-parser/lib/PhpParser/Node/Param.php @@ -16,6 +16,10 @@ class Param extends NodeAbstract public $var; /** @var null|Expr Default value */ public $default; + /** @var int */ + public $flags; + /** @var AttributeGroup[] PHP attribute groups */ + public $attrGroups; /** * Constructs a parameter node. @@ -26,10 +30,15 @@ class Param extends NodeAbstract * @param bool $byRef Whether is passed by reference * @param bool $variadic Whether this is a variadic argument * @param array $attributes Additional attributes + * @param int $flags Optional visibility flags + * @param AttributeGroup[] $attrGroups PHP attribute groups */ public function __construct( $var, Expr $default = null, $type = null, - bool $byRef = false, bool $variadic = false, array $attributes = [] + bool $byRef = false, bool $variadic = false, + array $attributes = [], + int $flags = 0, + array $attrGroups = [] ) { $this->attributes = $attributes; $this->type = \is_string($type) ? new Identifier($type) : $type; @@ -37,10 +46,12 @@ public function __construct( $this->variadic = $variadic; $this->var = $var; $this->default = $default; + $this->flags = $flags; + $this->attrGroups = $attrGroups; } public function getSubNodeNames() : array { - return ['type', 'byRef', 'variadic', 'var', 'default']; + return ['attrGroups', 'flags', 'type', 'byRef', 'variadic', 'var', 'default']; } public function getType() : string { diff --git a/nikic/php-parser/lib/PhpParser/Node/Stmt/Catch_.php b/nikic/php-parser/lib/PhpParser/Node/Stmt/Catch_.php index 7d4a7034b..9b9c09478 100644 --- a/nikic/php-parser/lib/PhpParser/Node/Stmt/Catch_.php +++ b/nikic/php-parser/lib/PhpParser/Node/Stmt/Catch_.php @@ -9,7 +9,7 @@ class Catch_ extends Node\Stmt { /** @var Node\Name[] Types of exceptions to catch */ public $types; - /** @var Expr\Variable Variable for exception */ + /** @var Expr\Variable|null Variable for exception */ public $var; /** @var Node\Stmt[] Statements */ public $stmts; @@ -17,13 +17,13 @@ class Catch_ extends Node\Stmt /** * Constructs a catch node. * - * @param Node\Name[] $types Types of exceptions to catch - * @param Expr\Variable $var Variable for exception - * @param Node\Stmt[] $stmts Statements - * @param array $attributes Additional attributes + * @param Node\Name[] $types Types of exceptions to catch + * @param Expr\Variable|null $var Variable for exception + * @param Node\Stmt[] $stmts Statements + * @param array $attributes Additional attributes */ public function __construct( - array $types, Expr\Variable $var, array $stmts = [], array $attributes = [] + array $types, Expr\Variable $var = null, array $stmts = [], array $attributes = [] ) { $this->attributes = $attributes; $this->types = $types; @@ -34,7 +34,7 @@ public function __construct( public function getSubNodeNames() : array { return ['types', 'var', 'stmts']; } - + public function getType() : string { return 'Stmt_Catch'; } diff --git a/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassConst.php b/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassConst.php index 73a501030..c459acb15 100644 --- a/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassConst.php +++ b/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassConst.php @@ -10,22 +10,31 @@ class ClassConst extends Node\Stmt public $flags; /** @var Node\Const_[] Constant declarations */ public $consts; + /** @var Node\AttributeGroup[] */ + public $attrGroups; /** * Constructs a class const list node. * - * @param Node\Const_[] $consts Constant declarations - * @param int $flags Modifiers - * @param array $attributes Additional attributes + * @param Node\Const_[] $consts Constant declarations + * @param int $flags Modifiers + * @param array $attributes Additional attributes + * @param Node\AttributeGroup[] $attrGroups PHP attribute groups */ - public function __construct(array $consts, int $flags = 0, array $attributes = []) { + public function __construct( + array $consts, + int $flags = 0, + array $attributes = [], + array $attrGroups = [] + ) { $this->attributes = $attributes; $this->flags = $flags; $this->consts = $consts; + $this->attrGroups = $attrGroups; } public function getSubNodeNames() : array { - return ['flags', 'consts']; + return ['attrGroups', 'flags', 'consts']; } /** @@ -55,7 +64,7 @@ public function isProtected() : bool { public function isPrivate() : bool { return (bool) ($this->flags & Class_::MODIFIER_PRIVATE); } - + public function getType() : string { return 'Stmt_ClassConst'; } diff --git a/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassLike.php b/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassLike.php index b1cd32639..840c4f67e 100644 --- a/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassLike.php +++ b/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassLike.php @@ -13,6 +13,8 @@ abstract class ClassLike extends Node\Stmt public $name; /** @var Node\Stmt[] Statements */ public $stmts; + /** @var Node\AttributeGroup[] PHP attribute groups */ + public $attrGroups; /** * @return TraitUse[] @@ -53,6 +55,26 @@ public function getProperties() : array { return $properties; } + /** + * Gets property with the given name defined directly in this class/interface/trait. + * + * @param string $name Name of the property + * + * @return Property|null Property node or null if the property does not exist + */ + public function getProperty(string $name) { + foreach ($this->stmts as $stmt) { + if ($stmt instanceof Property) { + foreach ($stmt->props as $prop) { + if ($prop instanceof PropertyProperty && $name === $prop->name->toString()) { + return $stmt; + } + } + } + } + return null; + } + /** * Gets all methods defined directly in this class/interface/trait * diff --git a/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassMethod.php b/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassMethod.php index 31cb4f1ea..92157fab2 100644 --- a/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassMethod.php +++ b/nikic/php-parser/lib/PhpParser/Node/Stmt/ClassMethod.php @@ -19,6 +19,8 @@ class ClassMethod extends Node\Stmt implements FunctionLike public $returnType; /** @var Node\Stmt[]|null Statements */ public $stmts; + /** @var Node\AttributeGroup[] PHP attribute groups */ + public $attrGroups; private static $magicNames = [ '__construct' => true, @@ -48,6 +50,7 @@ class ClassMethod extends Node\Stmt implements FunctionLike * 'params' => array() : Parameters * 'returnType' => null : Return type * 'stmts' => array() : Statements + * 'attrGroups' => array() : PHP attribute groups * @param array $attributes Additional attributes */ public function __construct($name, array $subNodes = [], array $attributes = []) { @@ -59,10 +62,11 @@ public function __construct($name, array $subNodes = [], array $attributes = []) $returnType = $subNodes['returnType'] ?? null; $this->returnType = \is_string($returnType) ? new Node\Identifier($returnType) : $returnType; $this->stmts = array_key_exists('stmts', $subNodes) ? $subNodes['stmts'] : []; + $this->attrGroups = $subNodes['attrGroups'] ?? []; } public function getSubNodeNames() : array { - return ['flags', 'byRef', 'name', 'params', 'returnType', 'stmts']; + return ['attrGroups', 'flags', 'byRef', 'name', 'params', 'returnType', 'stmts']; } public function returnsByRef() : bool { @@ -81,6 +85,10 @@ public function getStmts() { return $this->stmts; } + public function getAttrGroups() : array { + return $this->attrGroups; + } + /** * Whether the method is explicitly or implicitly public. * @@ -120,7 +128,7 @@ public function isAbstract() : bool { /** * Whether the method is final. - * + * * @return bool */ public function isFinal() : bool { @@ -144,7 +152,7 @@ public function isStatic() : bool { public function isMagic() : bool { return isset(self::$magicNames[$this->name->toLowerString()]); } - + public function getType() : string { return 'Stmt_ClassMethod'; } diff --git a/nikic/php-parser/lib/PhpParser/Node/Stmt/Class_.php b/nikic/php-parser/lib/PhpParser/Node/Stmt/Class_.php index e2a92e9ed..ace266f74 100644 --- a/nikic/php-parser/lib/PhpParser/Node/Stmt/Class_.php +++ b/nikic/php-parser/lib/PhpParser/Node/Stmt/Class_.php @@ -28,10 +28,11 @@ class Class_ extends ClassLike * * @param string|Node\Identifier|null $name Name * @param array $subNodes Array of the following optional subnodes: - * 'flags' => 0 : Flags - * 'extends' => null : Name of extended class - * 'implements' => array(): Names of implemented interfaces - * 'stmts' => array(): Statements + * 'flags' => 0 : Flags + * 'extends' => null : Name of extended class + * 'implements' => array(): Names of implemented interfaces + * 'stmts' => array(): Statements + * '$attrGroups' => array(): PHP attribute groups * @param array $attributes Additional attributes */ public function __construct($name, array $subNodes = [], array $attributes = []) { @@ -41,10 +42,11 @@ public function __construct($name, array $subNodes = [], array $attributes = []) $this->extends = $subNodes['extends'] ?? null; $this->implements = $subNodes['implements'] ?? []; $this->stmts = $subNodes['stmts'] ?? []; + $this->attrGroups = $subNodes['attrGroups'] ?? []; } public function getSubNodeNames() : array { - return ['flags', 'name', 'extends', 'implements', 'stmts']; + return ['attrGroups', 'flags', 'name', 'extends', 'implements', 'stmts']; } /** diff --git a/nikic/php-parser/lib/PhpParser/Node/Stmt/Function_.php b/nikic/php-parser/lib/PhpParser/Node/Stmt/Function_.php index 30e15578d..f08481fae 100644 --- a/nikic/php-parser/lib/PhpParser/Node/Stmt/Function_.php +++ b/nikic/php-parser/lib/PhpParser/Node/Stmt/Function_.php @@ -20,6 +20,8 @@ class Function_ extends Node\Stmt implements FunctionLike public $returnType; /** @var Node\Stmt[] Statements */ public $stmts; + /** @var Node\AttributeGroup[] PHP attribute groups */ + public $attrGroups; /** * Constructs a function node. @@ -30,6 +32,7 @@ class Function_ extends Node\Stmt implements FunctionLike * 'params' => array(): Parameters * 'returnType' => null : Return type * 'stmts' => array(): Statements + * 'attrGroups' => array(): PHP attribute groups * @param array $attributes Additional attributes */ public function __construct($name, array $subNodes = [], array $attributes = []) { @@ -40,10 +43,11 @@ public function __construct($name, array $subNodes = [], array $attributes = []) $returnType = $subNodes['returnType'] ?? null; $this->returnType = \is_string($returnType) ? new Node\Identifier($returnType) : $returnType; $this->stmts = $subNodes['stmts'] ?? []; + $this->attrGroups = $subNodes['attrGroups'] ?? []; } public function getSubNodeNames() : array { - return ['byRef', 'name', 'params', 'returnType', 'stmts']; + return ['attrGroups', 'byRef', 'name', 'params', 'returnType', 'stmts']; } public function returnsByRef() : bool { @@ -58,11 +62,15 @@ public function getReturnType() { return $this->returnType; } + public function getAttrGroups() : array { + return $this->attrGroups; + } + /** @return Node\Stmt[] */ public function getStmts() : array { return $this->stmts; } - + public function getType() : string { return 'Stmt_Function'; } diff --git a/nikic/php-parser/lib/PhpParser/Node/Stmt/Interface_.php b/nikic/php-parser/lib/PhpParser/Node/Stmt/Interface_.php index cf5d62a93..4d587dd48 100644 --- a/nikic/php-parser/lib/PhpParser/Node/Stmt/Interface_.php +++ b/nikic/php-parser/lib/PhpParser/Node/Stmt/Interface_.php @@ -14,8 +14,9 @@ class Interface_ extends ClassLike * * @param string|Node\Identifier $name Name * @param array $subNodes Array of the following optional subnodes: - * 'extends' => array(): Name of extended interfaces - * 'stmts' => array(): Statements + * 'extends' => array(): Name of extended interfaces + * 'stmts' => array(): Statements + * 'attrGroups' => array(): PHP attribute groups * @param array $attributes Additional attributes */ public function __construct($name, array $subNodes = [], array $attributes = []) { @@ -23,10 +24,11 @@ public function __construct($name, array $subNodes = [], array $attributes = []) $this->name = \is_string($name) ? new Node\Identifier($name) : $name; $this->extends = $subNodes['extends'] ?? []; $this->stmts = $subNodes['stmts'] ?? []; + $this->attrGroups = $subNodes['attrGroups'] ?? []; } public function getSubNodeNames() : array { - return ['name', 'extends', 'stmts']; + return ['attrGroups', 'name', 'extends', 'stmts']; } public function getType() : string { diff --git a/nikic/php-parser/lib/PhpParser/Node/Stmt/Property.php b/nikic/php-parser/lib/PhpParser/Node/Stmt/Property.php index 4d3ae649e..324345b85 100644 --- a/nikic/php-parser/lib/PhpParser/Node/Stmt/Property.php +++ b/nikic/php-parser/lib/PhpParser/Node/Stmt/Property.php @@ -16,6 +16,8 @@ class Property extends Node\Stmt public $props; /** @var null|Identifier|Name|NullableType|UnionType Type declaration */ public $type; + /** @var Node\AttributeGroup[] PHP attribute groups */ + public $attrGroups; /** * Constructs a class property list node. @@ -24,16 +26,18 @@ class Property extends Node\Stmt * @param PropertyProperty[] $props Properties * @param array $attributes Additional attributes * @param null|string|Identifier|Name|NullableType|UnionType $type Type declaration + * @param Node\AttributeGroup[] $attrGroups PHP attribute groups */ - public function __construct(int $flags, array $props, array $attributes = [], $type = null) { + public function __construct(int $flags, array $props, array $attributes = [], $type = null, array $attrGroups = []) { $this->attributes = $attributes; $this->flags = $flags; $this->props = $props; $this->type = \is_string($type) ? new Identifier($type) : $type; + $this->attrGroups = $attrGroups; } public function getSubNodeNames() : array { - return ['flags', 'type', 'props']; + return ['attrGroups', 'flags', 'type', 'props']; } /** diff --git a/nikic/php-parser/lib/PhpParser/Node/Stmt/Throw_.php b/nikic/php-parser/lib/PhpParser/Node/Stmt/Throw_.php index f97f56718..a34e2b362 100644 --- a/nikic/php-parser/lib/PhpParser/Node/Stmt/Throw_.php +++ b/nikic/php-parser/lib/PhpParser/Node/Stmt/Throw_.php @@ -10,7 +10,7 @@ class Throw_ extends Node\Stmt public $expr; /** - * Constructs a throw node. + * Constructs a legacy throw statement node. * * @param Node\Expr $expr Expression * @param array $attributes Additional attributes diff --git a/nikic/php-parser/lib/PhpParser/Node/Stmt/Trait_.php b/nikic/php-parser/lib/PhpParser/Node/Stmt/Trait_.php index c2e8cca37..0cec203ac 100644 --- a/nikic/php-parser/lib/PhpParser/Node/Stmt/Trait_.php +++ b/nikic/php-parser/lib/PhpParser/Node/Stmt/Trait_.php @@ -11,17 +11,19 @@ class Trait_ extends ClassLike * * @param string|Node\Identifier $name Name * @param array $subNodes Array of the following optional subnodes: - * 'stmts' => array(): Statements + * 'stmts' => array(): Statements + * 'attrGroups' => array(): PHP attribute groups * @param array $attributes Additional attributes */ public function __construct($name, array $subNodes = [], array $attributes = []) { $this->attributes = $attributes; $this->name = \is_string($name) ? new Node\Identifier($name) : $name; $this->stmts = $subNodes['stmts'] ?? []; + $this->attrGroups = $subNodes['attrGroups'] ?? []; } public function getSubNodeNames() : array { - return ['name', 'stmts']; + return ['attrGroups', 'name', 'stmts']; } public function getType() : string { diff --git a/nikic/php-parser/lib/PhpParser/NodeAbstract.php b/nikic/php-parser/lib/PhpParser/NodeAbstract.php index fda595994..04514da11 100644 --- a/nikic/php-parser/lib/PhpParser/NodeAbstract.php +++ b/nikic/php-parser/lib/PhpParser/NodeAbstract.php @@ -108,22 +108,18 @@ public function getComments() : array { /** * Gets the doc comment of the node. * - * The doc comment has to be the last comment associated with the node. - * * @return null|Comment\Doc Doc comment object or null */ public function getDocComment() { $comments = $this->getComments(); - if (!$comments) { - return null; - } - - $lastComment = $comments[count($comments) - 1]; - if (!$lastComment instanceof Comment\Doc) { - return null; + for ($i = count($comments) - 1; $i >= 0; $i--) { + $comment = $comments[$i]; + if ($comment instanceof Comment\Doc) { + return $comment; + } } - return $lastComment; + return null; } /** @@ -135,16 +131,17 @@ public function getDocComment() { */ public function setDocComment(Comment\Doc $docComment) { $comments = $this->getComments(); - - $numComments = count($comments); - if ($numComments > 0 && $comments[$numComments - 1] instanceof Comment\Doc) { - // Replace existing doc comment - $comments[$numComments - 1] = $docComment; - } else { - // Append new comment - $comments[] = $docComment; + for ($i = count($comments) - 1; $i >= 0; $i--) { + if ($comments[$i] instanceof Comment\Doc) { + // Replace existing doc comment. + $comments[$i] = $docComment; + $this->setAttribute('comments', $comments); + return; + } } + // Append new doc comment. + $comments[] = $docComment; $this->setAttribute('comments', $comments); } diff --git a/nikic/php-parser/lib/PhpParser/NodeVisitor/NameResolver.php b/nikic/php-parser/lib/PhpParser/NodeVisitor/NameResolver.php index a7fd95367..c55532a5e 100644 --- a/nikic/php-parser/lib/PhpParser/NodeVisitor/NameResolver.php +++ b/nikic/php-parser/lib/PhpParser/NodeVisitor/NameResolver.php @@ -75,6 +75,7 @@ public function enterNode(Node $node) { $interface = $this->resolveClassName($interface); } + $this->resolveAttrGroups($node); if (null !== $node->name) { $this->addNamespacedName($node); } @@ -83,25 +84,32 @@ public function enterNode(Node $node) { $interface = $this->resolveClassName($interface); } + $this->resolveAttrGroups($node); $this->addNamespacedName($node); } elseif ($node instanceof Stmt\Trait_) { + $this->resolveAttrGroups($node); $this->addNamespacedName($node); } elseif ($node instanceof Stmt\Function_) { - $this->addNamespacedName($node); $this->resolveSignature($node); + $this->resolveAttrGroups($node); + $this->addNamespacedName($node); } elseif ($node instanceof Stmt\ClassMethod || $node instanceof Expr\Closure || $node instanceof Expr\ArrowFunction ) { $this->resolveSignature($node); + $this->resolveAttrGroups($node); } elseif ($node instanceof Stmt\Property) { if (null !== $node->type) { $node->type = $this->resolveType($node->type); } + $this->resolveAttrGroups($node); } elseif ($node instanceof Stmt\Const_) { foreach ($node->consts as $const) { $this->addNamespacedName($const); } + } else if ($node instanceof Stmt\ClassConst) { + $this->resolveAttrGroups($node); } elseif ($node instanceof Expr\StaticCall || $node instanceof Expr\StaticPropertyFetch || $node instanceof Expr\ClassConstFetch @@ -157,6 +165,7 @@ private function addAlias(Stmt\UseUse $use, $type, Name $prefix = null) { private function resolveSignature($node) { foreach ($node->params as $param) { $param->type = $this->resolveType($param->type); + $this->resolveAttrGroups($param); } $node->returnType = $this->resolveType($node->returnType); } @@ -225,4 +234,13 @@ protected function addNamespacedName(Node $node) { $node->namespacedName = Name::concat( $this->nameContext->getNamespace(), (string) $node->name); } + + protected function resolveAttrGroups(Node $node) + { + foreach ($node->attrGroups as $attrGroup) { + foreach ($attrGroup->attrs as $attr) { + $attr->name = $this->resolveClassName($attr->name); + } + } + } } diff --git a/nikic/php-parser/lib/PhpParser/NodeVisitor/NodeConnectingVisitor.php b/nikic/php-parser/lib/PhpParser/NodeVisitor/NodeConnectingVisitor.php new file mode 100644 index 000000000..ea372e5b9 --- /dev/null +++ b/nikic/php-parser/lib/PhpParser/NodeVisitor/NodeConnectingVisitor.php @@ -0,0 +1,52 @@ +$node->getAttribute('parent'), the previous + * node can be accessed through $node->getAttribute('previous'), + * and the next node can be accessed through $node->getAttribute('next'). + */ +final class NodeConnectingVisitor extends NodeVisitorAbstract +{ + /** + * @var Node[] + */ + private $stack = []; + + /** + * @var ?Node + */ + private $previous; + + public function beforeTraverse(array $nodes) { + $this->stack = []; + $this->previous = null; + } + + public function enterNode(Node $node) { + if (!empty($this->stack)) { + $node->setAttribute('parent', $this->stack[count($this->stack) - 1]); + } + + if ($this->previous !== null && $this->previous->getAttribute('parent') === $node->getAttribute('parent')) { + $node->setAttribute('previous', $this->previous); + $this->previous->setAttribute('next', $node); + } + + $this->stack[] = $node; + } + + public function leaveNode(Node $node) { + $this->previous = $node; + + array_pop($this->stack); + } +} diff --git a/nikic/php-parser/lib/PhpParser/NodeVisitor/ParentConnectingVisitor.php b/nikic/php-parser/lib/PhpParser/NodeVisitor/ParentConnectingVisitor.php new file mode 100644 index 000000000..b98d2bfa6 --- /dev/null +++ b/nikic/php-parser/lib/PhpParser/NodeVisitor/ParentConnectingVisitor.php @@ -0,0 +1,41 @@ +$node->getAttribute('parent'). + */ +final class ParentConnectingVisitor extends NodeVisitorAbstract +{ + /** + * @var Node[] + */ + private $stack = []; + + public function beforeTraverse(array $nodes) + { + $this->stack = []; + } + + public function enterNode(Node $node) + { + if (!empty($this->stack)) { + $node->setAttribute('parent', $this->stack[count($this->stack) - 1]); + } + + $this->stack[] = $node; + } + + public function leaveNode(Node $node) + { + array_pop($this->stack); + } +} diff --git a/nikic/php-parser/lib/PhpParser/Parser/Php5.php b/nikic/php-parser/lib/PhpParser/Parser/Php5.php index a558d28b7..c67a5e707 100644 --- a/nikic/php-parser/lib/PhpParser/Parser/Php5.php +++ b/nikic/php-parser/lib/PhpParser/Parser/Php5.php @@ -17,21 +17,22 @@ */ class Php5 extends \PhpParser\ParserAbstract { - protected $tokenToSymbolMapSize = 394; - protected $actionTableSize = 1079; - protected $gotoTableSize = 650; + protected $tokenToSymbolMapSize = 392; + protected $actionTableSize = 1069; + protected $gotoTableSize = 580; - protected $invalidSymbol = 159; + protected $invalidSymbol = 165; protected $errorSymbol = 1; protected $defaultAction = -32766; protected $unexpectedTokenRule = 32767; - protected $YY2TBLSTATE = 407; - protected $numNonLeafStates = 676; + protected $YY2TBLSTATE = 405; + protected $numNonLeafStates = 658; protected $symbolToName = array( "EOF", "error", + "T_THROW", "T_INCLUDE", "T_INCLUDE_ONCE", "T_EVAL", @@ -127,6 +128,7 @@ class Php5 extends \PhpParser\ParserAbstract "T_ENDDECLARE", "T_AS", "T_SWITCH", + "T_MATCH", "T_ENDSWITCH", "T_CASE", "T_DEFAULT", @@ -140,7 +142,6 @@ class Php5 extends \PhpParser\ParserAbstract "T_TRY", "T_CATCH", "T_FINALLY", - "T_THROW", "T_USE", "T_INSTEADOF", "T_GLOBAL", @@ -180,6 +181,9 @@ class Php5 extends \PhpParser\ParserAbstract "T_DIR", "T_NS_SEPARATOR", "T_ELLIPSIS", + "T_NAME_FULLY_QUALIFIED", + "T_NAME_QUALIFIED", + "T_NAME_RELATIVE", "';'", "'{'", "'}'", @@ -188,348 +192,346 @@ class Php5 extends \PhpParser\ParserAbstract "'$'", "'`'", "']'", - "'\"'" + "'\"'", + "T_NULLSAFE_OBJECT_OPERATOR", + "T_ATTRIBUTE" ); protected $tokenToSymbol = array( - 0, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 54, 158, 159, 155, 53, 36, 159, - 153, 154, 51, 48, 7, 49, 50, 52, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 30, 150, - 42, 15, 44, 29, 66, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 68, 159, 157, 35, 159, 156, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 151, 34, 152, 56, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 1, 2, 3, 4, - 5, 6, 8, 9, 10, 11, 12, 13, 14, 16, + 0, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 55, 162, 165, 159, 54, 37, 165, + 157, 158, 52, 49, 8, 50, 51, 53, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 31, 154, + 43, 16, 45, 30, 67, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 69, 165, 161, 36, 165, 160, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 155, 35, 156, 57, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 1, 2, 3, 4, + 5, 6, 7, 9, 10, 11, 12, 13, 14, 15, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, - 27, 28, 31, 32, 33, 37, 38, 39, 40, 41, - 43, 45, 46, 47, 55, 57, 58, 59, 60, 61, - 62, 63, 64, 65, 67, 69, 70, 71, 72, 73, - 74, 75, 76, 77, 78, 79, 80, 81, 82, 159, - 159, 83, 84, 85, 86, 87, 88, 89, 90, 91, - 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, - 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, - 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, - 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, - 132, 133, 134, 135, 136, 137, 138, 139, 159, 159, - 159, 159, 159, 159, 140, 141, 142, 143, 144, 145, - 146, 147, 148, 149 + 27, 28, 29, 32, 33, 34, 38, 39, 40, 41, + 42, 44, 46, 47, 48, 56, 58, 59, 60, 61, + 62, 63, 64, 65, 66, 68, 70, 71, 72, 73, + 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, + 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, + 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, + 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, + 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, + 124, 125, 126, 127, 128, 129, 130, 131, 163, 132, + 133, 134, 135, 136, 137, 138, 139, 140, 141, 142, + 143, 144, 145, 146, 147, 148, 149, 150, 151, 152, + 153, 164 ); protected $action = array( - 681, 682, 683, 684, 685, 283, 686, 687, 688, 724, - 725, 222, 223, 224, 225, 226, 227, 228, 229, 230, - 0, 231, 232, 233, 234, 235, 236, 237, 238, 239, - 240, 241, 242,-32766,-32766,-32766,-32766,-32766,-32766,-32766, - -32766,-32767,-32767,-32767,-32767, 1052, 243, 244,-32766,-32766, - -32766,-32766,-32766, 689,-32766,-32766,-32766,-32766,-32766,-32766, - -32766,-32766,-32767,-32767,-32767,-32767,-32767, 690, 691, 692, - 693, 694, 695, 696, 834, 27, 757, 959, 960, 961, - 958, 957, 956, 697, 698, 699, 700, 701, 702, 703, - 704, 705, 706, 707, 727, 728, 729, 730, 731, 719, - 720, 721, 749, 722, 723, 708, 709, 710, 711, 712, - 713, 714, 751, 752, 753, 754, 755, 756, 715, 716, - 717, 718, 748, 739, 737, 738, 734, 735, 1188, 726, - 732, 733, 740, 741, 743, 742, 744, 745, 54, 55, - 426, 56, 57, 736, 747, 746, -220, 58, 59, 419, - 60,-32766,-32766,-32766,-32766,-32766,-32766,-32766,-32766,-32766, - 28,-32767,-32767,-32767,-32767,-32767,-32767,-32767,-32767, 97, - 98, 99, 100, 101, 9, 906, 907,-32766, 1202, 761, - 328, 764, 1188, 814, 61, 62, 52, 285, 500, 951, - 63, 434, 64, 294, 295, 65, 66, 67, 68, 69, - 70, 71, 72, 340, 25, 302, 73, 418,-32766,-32766, - -32766, 882, 1103, 1104, 761, 1080, 764,-32766,-32766,-32766, - 475, -255, 298, 825, 835, 759, 219, 220, 221,-32766, - 36,-32766,-32766,-32766,-32766,-32766,-32766, 125,-32766, 438, - -32766,-32766,-32766,-32766,-32766, 1052, 500, 206, 310, 434, - 499, 423, 1052, 129, 439, 759, 336, 340, 483, 484, - 10, 959, 960, 961, 958, 957, 956, 485, 486, 124, - 1109, 1110, 1111, 1112, 1106, 1107, 313,-32766,-32766,-32766, - -32766, 500, 1113, 1108, 434, 219, 220, 221, 425, 41, - 764, 336, 324, 1222, 325, 427, -126, -126, -126, -4, - 835, 474,-32766,-32766,-32766, 823, 206, 913, 40, 21, - 428, -126, 476, -126, 477, -126, 478, -126, 123, 429, - 219, 220, 221, 31, 32, 430, 431, 354, 130, 33, - 479, 883, 336, 74, 1203, 128, 352, 353, 480, 481, - 912, 206, 247, 301, 482, 210, 1052, 806, 853, 432, - 433, 312, 30, 297, 35, 106, 107, 108, 109, 110, - 111, 112, 113, 114, 115, 116, 117, 118, 421, 1052, - 296, 427, 1154, 837, 647, -126, 835, 474, 102, 103, - 104, 823, 304, 816, 40, 21, 428, 332, 476, 632, - 477, 422, 478, 298, 105, 429, 991, 993, 20, 31, - 32, 430, 431, 933, 409, 33, 479, 220, 221, 74, - 323,-32766, 352, 353, 480, 481,-32766,-32766,-32766, 424, - 482, 1052, 448, 768, 853, 432, 433, 206,-32766,-32766, - -32766, 48, 906, 907, 1153, 1070, 339,-32766, 485,-32766, - -32766,-32766,-32766, 1231, 337, 500, 1232, 427, 434, 837, - 647, -4, 835, 474, -224, 1052, 633, 823, 49, 434, - 40, 21, 428, 937, 476, 776, 477, 777, 478, -504, - 820, 429, -205, -205, -205, 31, 32, 430, 431,-32766, - -32766, 33, 479, 75,-32766, 74,-32766, 594, 352, 353, - 480, 481,-32766,-32766,-32766, 119, 482, 526, 451, 806, - 853, 432, 433, 240, 241, 242, 128,-32766,-32766,-32766, - 411, 775, 51,-32766, 120,-32766,-32766,-32766, 500, 243, - 244, 434, 552, 427, 417, 837, 647, -205,-32766, 474, - -32766,-32766, 1052, 823, 821, 351, 40, 21, 428, 1052, - 476, 121, 477, 449, 478, 1115, 211, 429, -204, -204, - -204, 31, 32, 430, 431, 1115, 286, 33, 479, 818, - 835, 74, 932, 299, 352, 353, 480, 481, 212, 219, - 220, 221, 482, 335, 245, 806, 853, 432, 433,-32766, - -32766,-32766, 213, 79, 80, 81, 99, 100, 101, 650, - 206, 237, 238, 239, 444, 122, 776, 649, 777, 300, - -32766, 837, 647, -204, 34, 248, 82, 83, 84, 85, - 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, - 96, 97, 98, 99, 100, 101, 102, 103, 104, 1052, - 304, 427, 221, 249, 835, 250, 78, 474, 206, 133, - 336, 823, 105, 585, 40, 21, 428, 127, 476, -83, - 477, 206, 478,-32766,-32766, 429, 219, 220, 221, 31, - 32, 430, 316, 651, 658, 33, 479, 835, 661, 74, - 243, 244, 352, 353, 458, 22, 833, 206, 463, 601, - 482, 134, 362, 132, 608, 609, 769, 653,-32766, 948, - 667, 936, 675, 846, 304, 105, 655, 43, 44, 45, - 616, 761, 759, 46, 47, 427, 302, -274, 50, 837, - 647, 474, 53, 131, 588, 823, 442, 468, 40, 21, - 428, 762, 476, 606, 477,-32766, 478, 764, 447, 429, - 964, 854, 532, 31, 32, 430, 855, 327, 427, 33, - 479, 835, 641, 74, 474, 620, 352, 353, 823, -81, - 628, 40, 21, 428, 482, 476, 11, 477, 450, 478, - 282, 591, 429, 375, 605, 848, 31, 32, 430, 0, - 659, 329, 33, 479, 835, 0, 74, 0, 0, 352, - 353, 0, 0, 837, 647, -504, 0, 482, 326, 0, - 331, 0, 0, 0, 0, 0, 0, 0, 309, 311, - -505, 0, 485, 664, 0, 0, 0, 0, 0, 0, - 0, 0, 427, 1114, 1160, 0, 869, 647, 474, -413, - -405, 835, 823, 5, 6, 40, 21, 428, 12, 476, - 14, 477, 361, 478, -414, 386, 429, 387, 24, 395, - 31, 32, 430, 444, 534, 427, 33, 479, 412, 413, - 74, 474, 38, 352, 353, 823, 39, 670, 40, 21, - 428, 482, 476, 671, 477, 774, 478, 824, 832, 429, - 811, 826, 885, 31, 32, 430, 876, 877, 809, 33, - 479, 870, 867, 74, 865, 943, 352, 353, 944, 941, - 837, 647, 427, 815, 482, 817, 819, 831, 474, 822, - 940, 772, 823, 773, 942, 40, 21, 428, 78, 476, - 648, 477, 652, 478, 654, 656, 429, 657, 246, 660, - 31, 32, 430, 837, 647, 662, 33, 479, 663, 665, - 74, 666, 126, 352, 353, 333, 214, 215, 334, 407, - 408, 482, 216, 672, 217, 807, 1228, 1230, 771, 852, - 770, 851, 1229, 850, 1066, 842, 208, 1054, 849, 1055, - 840, 214, 215, 949, 1103, 1104, 874, 216,-32766, 217, - 837, 647, 1105, 875, 462, 1227, 1196, 1194, 1179, 1192, - 1094, 208, 924, 1200, 1190, 780, 781, 778, 779, 1103, - 1104, 26, 29,-32766, 37, 42, 76, 1105, 77, 209, - 284, 292, 293, 305, 306, 307, 308, 341, 410, 416, - -32766, 0, -221, -220, 16, 17, 18, 380, 459, 466, - 573, 467, 1109, 1110, 1111, 1112, 1106, 1107, 385, 472, - 567, 638, 1057, 1060, 1113, 1108, 914, 1119, 1056, 1032, - 577, 218, 287,-32766, 1031, 573, 1096, 1109, 1110, 1111, - 1112, 1106, 1107, 385, -423, 1050, 0, 1061, 1063, 1113, - 1108, 1062, 1065, 1064, 1079, 1193, 218, 1178,-32766, 1174, - 0, 1191, 1093, 1225, 1120, 1173, 612, 0, 1159 + 693, 663, 664, 665, 666, 667, 282, 668, 669, 670, + 706, 707, 221, 222, 223, 224, 225, 226, 227, 228, + 229, 0, 230, 231, 232, 233, 234, 235, 236, 237, + 238, 239, 240, 241,-32766,-32766,-32766,-32766,-32766,-32766, + -32766,-32766,-32767,-32767,-32767,-32767, 27, 242, 243,-32766, + -32766,-32766,-32766,-32766, 671,-32766, 333,-32766,-32766,-32766, + -32766,-32766,-32766,-32767,-32767,-32767,-32767,-32767, 672, 673, + 674, 675, 676, 677, 678, 1034, 816, 740, 941, 942, + 943, 940, 939, 938, 679, 680, 681, 682, 683, 684, + 685, 686, 687, 688, 689, 709, 732, 710, 711, 712, + 713, 701, 702, 703, 731, 704, 705, 690, 691, 692, + 694, 695, 696, 734, 735, 736, 737, 738, 739, 697, + 698, 699, 700, 730, 721, 719, 720, 716, 717, 437, + 708, 714, 715, 722, 723, 725, 724, 726, 727, 55, + 56, 417, 57, 58, 718, 729, 728, 28, 59, 60, + -220, 61,-32766,-32766,-32766,-32766,-32766,-32766,-32766,-32766, + -32766, 36,-32767,-32767,-32767,-32767, 1034, 35, 106, 107, + 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, + 118,-32766,-32766,-32766,-32766, 62, 63, 1034, 125, 285, + 292, 64, 748, 65, 290, 291, 66, 67, 68, 69, + 70, 71, 72, 73, 763, 25, 298, 74, 409, 973, + 975, 294, 294, 1086, 1087, 1064, 796, 748, 218, 219, + 220, 465,-32766,-32766,-32766, 742, 864, 817, 54, 807, + 9,-32766,-32766,-32766, 760, 320, 761, 410, 10, 202, + 246, 428, 209,-32766, 933,-32766,-32766,-32766,-32766,-32766, + -32766, 488,-32766, 438,-32766,-32766,-32766,-32766,-32766, 473, + 474, 941, 942, 943, 940, 939, 938,-32766, 475, 476, + 337, 1092, 1093, 1094, 1095, 1089, 1090, 315, 1214, -255, + 747, 1215, -505, 1096, 1091, 888, 889, 1066, 1065, 1067, + 218, 219, 220, 41, 414, 337, 330, 895, 332, 418, + -126, -126, -126, 75, 52, 464, -4, 817, 54, 805, + -224, 202, 40, 21, 419, -126, 466, -126, 467, -126, + 468, -126, 359, 420, 128, 128, 748, 1171, 31, 32, + 421, 422, 1034, 894, 33, 469,-32766,-32766,-32766, 1186, + 351, 352, 470, 471,-32766,-32766,-32766, 309, 472, 865, + 323, 788, 835, 423, 424,-32767,-32767,-32767,-32767, 97, + 98, 99, 100, 101, 615,-32766, 313,-32766,-32766,-32766, + -32766, 354, 1185, 1171, 218, 219, 220, 475, 748, 418, + 819, 629, -126, 297, 915, 464, 817, 54,-32766, 805, + 124, 748, 40, 21, 419, 202, 466, 48, 467, 534, + 468, 129, 429, 420, 337, 341, 888, 889, 31, 32, + 421, 422, 416, 405, 33, 469,-32766,-32766, 311, 298, + 351, 352, 470, 471,-32766,-32766,-32766, 748, 472, 412, + 748, 752, 835, 423, 424, 338, 1066, 1065, 1067, 219, + 220, 919, 1136, 296, 20,-32766, 576,-32766,-32766,-32766, + 742, 341, 342, 413, 429, 1064, 337, 512, 418, 202, + 819, 629, -4, 1034, 464, 817, 54, 49, 805, 337, + 762, 40, 21, 419, 51, 466, 1034, 467, 475, 468, + 340, 748, 420, 120, -205, -205, -205, 31, 32, 421, + 422, 1062,-32766, 33, 469,-32766,-32766,-32766, 744, 351, + 352, 470, 471, 429, 1098, 337, 429, 472, 337, 1034, + 788, 835, 423, 424, 415, 1098,-32766, 802,-32766,-32766, + 102, 103, 104, 1137, 303, 202, 130, 1066, 1065, 1067, + 337, 123, 239, 240, 241, 748, 105, 418, 1205, 819, + 629, -205, 440, 464,-32766,-32766,-32766, 805, 242, 243, + 40, 21, 419, 121, 466, 126, 467, 429, 468, 337, + 122, 420, 1052, -204, -204, -204, 31, 32, 421, 422, + 1034, 745, 33, 469, 220, 759, 817, 54, 351, 352, + 470, 471, 218, 219, 220, 119, 472, 244, 127, 788, + 835, 423, 424, 202,-32766,-32766,-32766, 30, 293, 803, + 79, 80, 81, 202, 798, 210, 632, 99, 100, 101, + 236, 237, 238, 817, 54,-32766, 211, 800, 819, 629, + -204, 34, 1034, 82, 83, 84, 85, 86, 87, 88, + 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, + 99, 100, 101, 102, 103, 104, 286, 303, 418, 1034, + 817, 54,-32766,-32766, 464, 218, 219, 220, 805, 105, + 914, 40, 21, 419, 78, 466, 212, 467, 337, 468, + 133, 247, 420, 295, 567, 248, 202, 31, 32, 421, + 633, 242, 243, 33, 469, 418, 249, 817, 54, 351, + 352, 464, 760, -84, 761, 805, 310, 472, 40, 21, + 419,-32766, 466, 640, 467, 643, 468, 447, 22, 420, + 815, 452, 584, 132, 31, 32, 421, 637, 134, 364, + 33, 469, 418, 303, 817, 54, 351, 352, 464, 819, + 629, 828, 805, 43, 472, 40, 21, 419, 44, 466, + 45, 467, 46, 468, 591, 592, 420, 753, 635, 930, + 649, 31, 32, 421, 641, 918, 657, 33, 469, 418, + 105, 817, 54, 351, 352, 464, 819, 629, 47, 805, + 50, 472, 40, 21, 419, 53, 466, 131, 467, 298, + 468, 599, 742, 420,-32766, -274, 516, 570, 31, 32, + 421, 646, 748, 946, 33, 469, 418, 589, 436,-32766, + 351, 352, 464, 819, 629, 623, 805, 836, 472, 40, + 21, 419, 611, 466, -82, 467, 603, 468, 11, 573, + 420, 439, 456, 281, 318, 31, 32, 421, 588, 432, + 321, 33, 469, 418, -414, 458, 322, 351, 352, 464, + 851, 629, 837, 805, -505, 472, 40, 21, 419, 654, + 466, 38, 467, 24, 468, 0, 0, 420, 319, 0, + -405, 0, 31, 32, 421, 245, 312, 314, 33, 469, + -506, 0, 0, 1097, 351, 352, 1143, 819, 629, 0, + 0, 527, 472, 213, 214, 6, 7, 12, 14, 215, + 363, 216, -415, 558, 789, -221, 830, 0, 0, 747, + 0, 0, 0, 207, 39, 652, 653, 758, 806, 814, + 793, 1086, 1087, 808, 819, 629, 213, 214, 867, 1088, + 858, 859, 215, 791, 216, 852, 849, 847, 925, 926, + 923, 813, 797, 799, 801, 804, 207, 922, 756, 757, + 924, 287, 78, 331, 1086, 1087, 353, 630, 634, 636, + 638, 639, 1088, 642, 644, 645, 647, 648, 631, 1142, + 1211, 1213, 755, 834, 754, 833, 1212, 554, 832, 1092, + 1093, 1094, 1095, 1089, 1090, 388, 1048, 824, 1036, 831, + 1037, 1096, 1091, 822, 931, 856, 857, 451, 1210, 1179, + 0, 217, 1177, 1162, 1175, 1077, 906, 1183, 1173, 0, + 554, 26, 1092, 1093, 1094, 1095, 1089, 1090, 388, 29, + 37, 42, 76, 77, 1096, 1091, 208, 284, 288, 289, + 304, 305, 306, 307, 217, 335, 406, 408, 0, -220, + 16, 17, 18, 383, 448, 455, 457, 462, 548, 620, + 1039, 1042, 896, 1102, 1038, 1014, 559, 1013, 1079, 0, + 0, -424, 1032, 0, 1043, 1045, 1044, 1047, 1046, 1061, + 1176, 1161, 1157, 1174, 1076, 1208, 1103, 1156, 595 ); protected $actionCheck = array( - 2, 3, 4, 5, 6, 13, 8, 9, 10, 11, - 12, 32, 33, 34, 35, 36, 37, 38, 39, 40, - 0, 42, 43, 44, 45, 46, 47, 48, 49, 50, - 51, 52, 53, 8, 9, 10, 32, 33, 34, 35, - 36, 37, 38, 39, 40, 12, 67, 68, 32, 33, - 34, 35, 36, 55, 29, 8, 31, 32, 33, 34, - 35, 36, 37, 38, 39, 40, 41, 69, 70, 71, - 72, 73, 74, 75, 1, 7, 78, 114, 115, 116, - 117, 118, 119, 85, 86, 87, 88, 89, 90, 91, + 2, 3, 4, 5, 6, 7, 14, 9, 10, 11, + 12, 13, 33, 34, 35, 36, 37, 38, 39, 40, + 41, 0, 43, 44, 45, 46, 47, 48, 49, 50, + 51, 52, 53, 54, 9, 10, 11, 33, 34, 35, + 36, 37, 38, 39, 40, 41, 8, 68, 69, 33, + 34, 35, 36, 37, 56, 30, 8, 32, 33, 34, + 35, 36, 37, 38, 39, 40, 41, 42, 70, 71, + 72, 73, 74, 75, 76, 13, 1, 79, 115, 116, + 117, 118, 119, 120, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, - 122, 123, 124, 125, 126, 127, 128, 129, 80, 131, - 132, 133, 134, 135, 136, 137, 138, 139, 2, 3, - 4, 5, 6, 145, 146, 147, 154, 11, 12, 125, - 14, 32, 33, 34, 35, 36, 37, 38, 39, 40, - 7, 42, 43, 44, 45, 42, 43, 44, 45, 46, - 47, 48, 49, 50, 105, 132, 133, 153, 1, 78, - 111, 80, 80, 150, 48, 49, 68, 7, 145, 120, - 54, 148, 56, 57, 58, 59, 60, 61, 62, 63, - 64, 65, 66, 155, 68, 69, 70, 71, 8, 9, - 10, 30, 76, 77, 78, 114, 80, 8, 9, 10, - 84, 152, 36, 150, 1, 78, 8, 9, 10, 29, - 13, 31, 32, 33, 34, 35, 36, 7, 29, 103, - 31, 32, 33, 34, 35, 12, 145, 29, 130, 148, - 114, 7, 12, 151, 153, 78, 155, 155, 122, 123, - 7, 114, 115, 116, 117, 118, 119, 131, 132, 151, - 134, 135, 136, 137, 138, 139, 140, 32, 33, 34, - 35, 145, 146, 147, 148, 8, 9, 10, 7, 153, - 80, 155, 156, 83, 158, 72, 73, 74, 75, 0, - 1, 78, 8, 9, 10, 82, 29, 154, 85, 86, - 87, 88, 89, 90, 91, 92, 93, 94, 13, 96, - 8, 9, 10, 100, 101, 102, 103, 7, 151, 106, - 107, 150, 155, 110, 154, 149, 113, 114, 115, 116, - 154, 29, 30, 36, 121, 7, 12, 124, 125, 126, - 127, 7, 142, 143, 15, 16, 17, 18, 19, 20, - 21, 22, 23, 24, 25, 26, 27, 28, 7, 12, - 36, 72, 154, 150, 151, 152, 1, 78, 51, 52, - 53, 82, 55, 150, 85, 86, 87, 7, 89, 78, - 91, 7, 93, 36, 67, 96, 57, 58, 154, 100, - 101, 102, 103, 150, 105, 106, 107, 9, 10, 110, - 111, 80, 113, 114, 115, 116, 8, 9, 10, 7, - 121, 12, 30, 124, 125, 126, 127, 29, 32, 33, - 34, 68, 132, 133, 157, 154, 68, 29, 131, 31, - 32, 33, 34, 78, 145, 145, 81, 72, 148, 150, - 151, 152, 1, 78, 154, 12, 145, 82, 68, 148, - 85, 86, 87, 152, 89, 103, 91, 105, 93, 130, - 150, 96, 97, 98, 99, 100, 101, 102, 103, 8, - 9, 106, 107, 149, 153, 110, 155, 83, 113, 114, - 115, 116, 8, 9, 10, 15, 121, 83, 130, 124, - 125, 126, 127, 51, 52, 53, 149, 8, 9, 10, - 148, 150, 68, 29, 151, 31, 32, 33, 145, 67, - 68, 148, 79, 72, 7, 150, 151, 152, 29, 78, - 31, 32, 12, 82, 150, 7, 85, 86, 87, 12, - 89, 151, 91, 151, 93, 141, 15, 96, 97, 98, - 99, 100, 101, 102, 103, 141, 36, 106, 107, 150, - 1, 110, 150, 36, 113, 114, 115, 116, 15, 8, - 9, 10, 121, 7, 13, 124, 125, 126, 127, 8, - 9, 10, 15, 8, 9, 10, 48, 49, 50, 30, - 29, 48, 49, 50, 148, 151, 103, 151, 105, 7, - 29, 150, 151, 152, 29, 15, 31, 32, 33, 34, - 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, - 45, 46, 47, 48, 49, 50, 51, 52, 53, 12, - 55, 72, 10, 15, 1, 15, 151, 78, 29, 151, - 155, 82, 67, 155, 85, 86, 87, 30, 89, 30, - 91, 29, 93, 32, 33, 96, 8, 9, 10, 100, - 101, 102, 30, 30, 30, 106, 107, 1, 30, 110, - 67, 68, 113, 114, 73, 74, 30, 29, 73, 74, - 121, 98, 99, 30, 108, 109, 150, 151, 32, 150, - 151, 150, 151, 36, 55, 67, 30, 68, 68, 68, - 75, 78, 78, 68, 68, 72, 69, 80, 68, 150, - 151, 78, 68, 68, 88, 82, 103, 103, 85, 86, - 87, 78, 89, 111, 91, 83, 93, 80, 87, 96, - 80, 125, 83, 100, 101, 102, 125, 129, 72, 106, - 107, 1, 90, 110, 78, 94, 113, 114, 82, 95, - 92, 85, 86, 87, 121, 89, 95, 91, 95, 93, - 95, 97, 96, 148, 97, 149, 100, 101, 102, -1, - 30, 112, 106, 107, 1, -1, 110, -1, -1, 113, - 114, -1, -1, 150, 151, 130, -1, 121, 128, -1, - 128, -1, -1, -1, -1, -1, -1, -1, 130, 130, - 130, -1, 131, 30, -1, -1, -1, -1, -1, -1, - -1, -1, 72, 141, 141, -1, 150, 151, 78, 144, - 144, 1, 82, 144, 144, 85, 86, 87, 144, 89, - 144, 91, 144, 93, 144, 148, 96, 148, 153, 148, - 100, 101, 102, 148, 148, 72, 106, 107, 148, 148, - 110, 78, 150, 113, 114, 82, 150, 150, 85, 86, - 87, 121, 89, 150, 91, 150, 93, 150, 150, 96, - 150, 150, 150, 100, 101, 102, 150, 150, 150, 106, - 107, 150, 150, 110, 150, 150, 113, 114, 150, 150, - 150, 151, 72, 150, 121, 150, 150, 150, 78, 150, - 150, 150, 82, 150, 150, 85, 86, 87, 151, 89, - 151, 91, 151, 93, 151, 151, 96, 151, 30, 151, - 100, 101, 102, 150, 151, 151, 106, 107, 151, 151, - 110, 151, 151, 113, 114, 151, 48, 49, 151, 151, - 151, 121, 54, 152, 56, 152, 152, 152, 152, 152, - 152, 152, 152, 152, 152, 152, 68, 152, 152, 152, - 152, 48, 49, 152, 76, 77, 152, 54, 80, 56, - 150, 151, 84, 152, 152, 152, 152, 152, 152, 152, - 152, 68, 152, 152, 152, 152, 152, 152, 152, 76, - 77, 153, 153, 80, 153, 153, 153, 84, 153, 153, - 153, 153, 153, 153, 153, 153, 153, 153, 153, 153, - 153, -1, 154, 154, 154, 154, 154, 154, 154, 154, - 132, 154, 134, 135, 136, 137, 138, 139, 140, 154, - 154, 154, 154, 154, 146, 147, 154, 154, 154, 154, - 154, 153, 155, 155, 154, 132, 154, 134, 135, 136, - 137, 138, 139, 140, 156, 156, -1, 157, 157, 146, - 147, 157, 157, 157, 157, 157, 153, 157, 155, 157, - -1, 157, 157, 157, 157, 157, 157, -1, 158 + 122, 123, 124, 125, 126, 127, 128, 129, 130, 31, + 132, 133, 134, 135, 136, 137, 138, 139, 140, 3, + 4, 5, 6, 7, 146, 147, 148, 8, 12, 13, + 158, 15, 33, 34, 35, 36, 37, 38, 39, 40, + 41, 14, 43, 44, 45, 46, 13, 16, 17, 18, + 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, + 29, 33, 34, 35, 36, 49, 50, 13, 8, 8, + 37, 55, 81, 57, 58, 59, 60, 61, 62, 63, + 64, 65, 66, 67, 156, 69, 70, 71, 72, 58, + 59, 37, 37, 77, 78, 79, 154, 81, 9, 10, + 11, 85, 9, 10, 11, 79, 31, 1, 2, 154, + 107, 9, 10, 11, 105, 112, 107, 126, 8, 30, + 31, 105, 8, 30, 121, 32, 33, 34, 35, 36, + 37, 115, 30, 155, 32, 33, 34, 35, 36, 123, + 124, 115, 116, 117, 118, 119, 120, 115, 132, 133, + 159, 135, 136, 137, 138, 139, 140, 141, 79, 156, + 151, 82, 131, 147, 148, 133, 134, 151, 152, 153, + 9, 10, 11, 157, 8, 159, 160, 158, 162, 73, + 74, 75, 76, 150, 69, 79, 0, 1, 2, 83, + 158, 30, 86, 87, 88, 89, 90, 91, 92, 93, + 94, 95, 8, 97, 150, 150, 81, 81, 102, 103, + 104, 105, 13, 158, 108, 109, 9, 10, 11, 158, + 114, 115, 116, 117, 9, 10, 11, 8, 122, 154, + 8, 125, 126, 127, 128, 43, 44, 45, 46, 47, + 48, 49, 50, 51, 79, 30, 131, 32, 33, 34, + 35, 8, 1, 81, 9, 10, 11, 132, 81, 73, + 154, 155, 156, 37, 154, 79, 1, 2, 115, 83, + 155, 81, 86, 87, 88, 30, 90, 69, 92, 80, + 94, 155, 157, 97, 159, 159, 133, 134, 102, 103, + 104, 105, 8, 107, 108, 109, 9, 10, 112, 70, + 114, 115, 116, 117, 9, 10, 11, 81, 122, 8, + 81, 125, 126, 127, 128, 8, 151, 152, 153, 10, + 11, 156, 161, 8, 158, 30, 84, 32, 33, 34, + 79, 159, 146, 8, 157, 79, 159, 84, 73, 30, + 154, 155, 156, 13, 79, 1, 2, 69, 83, 159, + 156, 86, 87, 88, 69, 90, 13, 92, 132, 94, + 69, 81, 97, 155, 99, 100, 101, 102, 103, 104, + 105, 115, 9, 108, 109, 9, 10, 11, 79, 114, + 115, 116, 117, 157, 142, 159, 157, 122, 159, 13, + 125, 126, 127, 128, 8, 142, 30, 154, 32, 33, + 52, 53, 54, 158, 56, 30, 155, 151, 152, 153, + 159, 14, 52, 53, 54, 81, 68, 73, 84, 154, + 155, 156, 131, 79, 33, 34, 35, 83, 68, 69, + 86, 87, 88, 155, 90, 155, 92, 157, 94, 159, + 155, 97, 158, 99, 100, 101, 102, 103, 104, 105, + 13, 152, 108, 109, 11, 154, 1, 2, 114, 115, + 116, 117, 9, 10, 11, 16, 122, 14, 31, 125, + 126, 127, 128, 30, 9, 10, 11, 143, 144, 154, + 9, 10, 11, 30, 154, 16, 31, 49, 50, 51, + 49, 50, 51, 1, 2, 30, 16, 154, 154, 155, + 156, 30, 13, 32, 33, 34, 35, 36, 37, 38, + 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, + 49, 50, 51, 52, 53, 54, 37, 56, 73, 13, + 1, 2, 33, 34, 79, 9, 10, 11, 83, 68, + 154, 86, 87, 88, 155, 90, 16, 92, 159, 94, + 155, 16, 97, 37, 159, 16, 30, 102, 103, 104, + 31, 68, 69, 108, 109, 73, 16, 1, 2, 114, + 115, 79, 105, 31, 107, 83, 31, 122, 86, 87, + 88, 33, 90, 31, 92, 31, 94, 74, 75, 97, + 31, 74, 75, 31, 102, 103, 104, 31, 100, 101, + 108, 109, 73, 56, 1, 2, 114, 115, 79, 154, + 155, 37, 83, 69, 122, 86, 87, 88, 69, 90, + 69, 92, 69, 94, 110, 111, 97, 154, 155, 154, + 155, 102, 103, 104, 31, 154, 155, 108, 109, 73, + 68, 1, 2, 114, 115, 79, 154, 155, 69, 83, + 69, 122, 86, 87, 88, 69, 90, 69, 92, 70, + 94, 76, 79, 97, 84, 81, 84, 89, 102, 103, + 104, 31, 81, 81, 108, 109, 73, 112, 88, 115, + 114, 115, 79, 154, 155, 91, 83, 126, 122, 86, + 87, 88, 93, 90, 96, 92, 95, 94, 96, 99, + 97, 96, 96, 96, 129, 102, 103, 104, 99, 105, + 113, 108, 109, 73, 145, 105, 129, 114, 115, 79, + 154, 155, 126, 83, 131, 122, 86, 87, 88, 156, + 90, 154, 92, 157, 94, -1, -1, 97, 130, -1, + 145, -1, 102, 103, 104, 31, 131, 131, 108, 109, + 131, -1, -1, 142, 114, 115, 142, 154, 155, -1, + -1, 149, 122, 49, 50, 145, 145, 145, 145, 55, + 145, 57, 145, 149, 156, 158, 150, -1, -1, 151, + -1, -1, -1, 69, 154, 154, 154, 154, 154, 154, + 154, 77, 78, 154, 154, 155, 49, 50, 154, 85, + 154, 154, 55, 154, 57, 154, 154, 154, 154, 154, + 154, 154, 154, 154, 154, 154, 69, 154, 154, 154, + 154, 159, 155, 155, 77, 78, 155, 155, 155, 155, + 155, 155, 85, 155, 155, 155, 155, 155, 155, 162, + 156, 156, 156, 156, 156, 156, 156, 133, 156, 135, + 136, 137, 138, 139, 140, 141, 156, 156, 156, 156, + 156, 147, 148, 156, 156, 156, 156, 156, 156, 156, + -1, 157, 156, 156, 156, 156, 156, 156, 156, -1, + 133, 157, 135, 136, 137, 138, 139, 140, 141, 157, + 157, 157, 157, 157, 147, 148, 157, 157, 157, 157, + 157, 157, 157, 157, 157, 157, 157, 157, -1, 158, + 158, 158, 158, 158, 158, 158, 158, 158, 158, 158, + 158, 158, 158, 158, 158, 158, 158, 158, 158, -1, + -1, 160, 160, -1, 161, 161, 161, 161, 161, 161, + 161, 161, 161, 161, 161, 161, 161, 161, 161 ); protected $actionBase = array( - 0, 223, 299, 375, 451, 102, 102, 311, 754, -2, - -2, 147, -2, -2, -2, 633, 740, 773, 740, 559, - 666, 820, 820, 820, 186, 334, 334, 334, 357, 892, - 443, 33, 233, 409, 617, 520, 527, 240, 240, 240, - 240, 136, 136, 240, 240, 240, 240, 240, 240, 240, - 240, 240, 240, 240, 240, 240, 240, 240, 240, 240, - 240, 240, 240, 240, 240, 240, 240, 240, 240, 240, - 240, 240, 240, 240, 240, 240, 240, 240, 240, 240, - 240, 240, 240, 240, 240, 240, 240, 240, 240, 240, - 240, 240, 240, 240, 240, 240, 240, 240, 240, 240, - 240, 240, 240, 240, 240, 240, 240, 240, 240, 240, - 240, 240, 240, 240, 240, 240, 240, 240, 240, 240, - 240, 240, 240, 240, 240, 240, 240, 240, 240, 240, - 240, 240, 240, 240, 240, 181, 73, 305, 217, 743, - 745, 746, 747, 884, 665, 885, 823, 824, 653, 825, - 826, 827, 828, 830, 822, 831, 919, 832, 575, 575, - 575, 575, 575, 575, 575, 575, 575, 575, 575, 575, - 47, 561, 218, 312, 277, 471, 648, 648, 648, 648, - 648, 648, 648, 294, 294, 294, 294, 294, 294, 294, - 294, 294, 294, 294, 294, 294, 294, 294, 294, 294, - 294, 398, 571, 571, 571, 622, 888, 609, 913, 913, - 913, 913, 913, 913, 913, 913, 913, 913, 913, 913, - 913, 913, 913, 913, 913, 913, 913, 913, 913, 913, - 913, 913, 913, 913, 913, 913, 913, 913, 913, 913, - 913, 913, 913, 913, 913, 913, 913, 913, 913, 913, - 913, 499, -21, -21, 484, 656, 408, 621, 209, 396, - 200, 25, 25, 25, 25, 25, 245, 16, 4, 4, - 4, 4, 339, 123, 123, 123, 123, 119, 119, 119, - 119, 69, 307, 307, 671, 671, 637, 781, 538, 538, - 543, 543, 101, 101, 101, 101, 101, 101, 101, 101, - 101, 101, 24, 627, 857, 300, 300, 300, 300, 177, - 177, 177, 43, 414, 673, 920, 43, 327, 327, 327, - 452, 452, 452, 362, 649, 210, 331, 331, 331, 331, - 210, 331, 331, 493, 493, 493, 485, 446, 642, 365, - 488, 373, 390, 664, 814, 667, 821, 541, 690, 118, - 700, 701, 887, 613, 887, 601, 605, 576, 676, 392, - 850, 48, 181, 539, 444, 639, 749, 361, 751, 320, - 384, 368, 536, 363, 244, 784, 753, 886, 890, 180, - 670, 639, 639, 639, 153, 404, 787, 788, 363, -8, - 603, 603, 603, 603, 833, 789, 603, 603, 603, 603, - 834, 835, 253, 412, 836, 281, 750, 623, 623, 624, - 624, 623, 623, 623, 623, 650, 657, 623, 839, 685, - 685, 624, 647, 624, 650, 657, 842, 842, 842, 842, - 624, 657, 624, 624, 623, 624, 685, 685, 657, 637, - 685, 68, 657, 660, 623, 662, 662, 842, 707, 713, - 624, 624, 608, 685, 685, 685, 608, 657, 842, 612, - 616, 338, 685, 842, 632, 647, 632, 612, 657, 632, - 647, 647, 632, 20, 619, 629, 841, 843, 855, 759, - 606, 611, 848, 849, 845, 847, 838, 646, 696, 715, - 717, 480, 630, 631, 635, 636, 679, 640, 668, 613, - 695, 628, 628, 628, 655, 680, 655, 628, 628, 628, - 628, 628, 628, 628, 628, 900, 675, 688, 669, 641, - 718, 531, 615, 663, 553, 761, 672, 696, 696, 793, - 878, 863, 898, 899, 643, 850, 876, 655, 901, 702, - 230, 567, 851, 791, 687, 689, 655, 852, 655, 763, - 655, 879, 794, 645, 795, 696, 796, 628, 882, 904, - 905, 906, 907, 908, 910, 912, 914, 644, 915, 720, - 626, 864, 344, 846, 676, 684, 691, 721, 797, 380, - 916, 798, 655, 655, 764, 757, 655, 766, 722, 706, - 860, 726, 865, 917, 672, 867, 655, 614, 799, 918, - 380, 634, 625, 858, 651, 727, 856, 883, 854, 768, - 590, 618, 800, 801, 802, 638, 728, 861, 862, 859, - 731, 774, 620, 777, 658, 803, 778, 853, 732, 805, - 806, 877, 654, 695, 686, 659, 661, 652, 780, 807, - 875, 734, 735, 738, 808, 739, 811, 0, 0, 0, + 0, 226, 306, 385, 464, 285, 246, 246, 786, -2, + -2, 146, -2, -2, -2, 649, 723, 760, 723, 575, + 686, 612, 612, 612, 175, 153, 153, 153, 174, 890, + 319, 62, 450, 463, 557, 609, 636, 496, 496, 496, + 496, 136, 136, 496, 496, 496, 496, 496, 496, 496, + 496, 496, 496, 496, 496, 496, 496, 496, 496, 496, + 496, 496, 496, 496, 496, 496, 496, 496, 496, 496, + 496, 496, 496, 496, 496, 496, 496, 496, 496, 496, + 496, 496, 496, 496, 496, 496, 496, 496, 496, 496, + 496, 496, 496, 496, 496, 496, 496, 496, 496, 496, + 496, 496, 496, 496, 496, 496, 496, 496, 496, 496, + 496, 496, 496, 496, 496, 496, 496, 496, 496, 496, + 496, 496, 496, 496, 496, 496, 496, 496, 496, 496, + 496, 496, 496, 496, 496, 195, 75, 777, 517, 147, + 778, 779, 780, 886, 727, 887, 832, 833, 682, 836, + 837, 838, 839, 840, 831, 841, 907, 842, 591, 591, + 591, 591, 591, 591, 591, 591, 591, 591, 591, 591, + 483, 573, 365, 209, 281, 407, 646, 646, 646, 646, + 646, 646, 646, 327, 327, 327, 327, 327, 327, 327, + 327, 327, 327, 327, 327, 327, 327, 327, 327, 327, + 327, 429, 834, 585, 585, 585, 563, 867, 867, 867, + 867, 867, 867, 867, 867, 867, 867, 867, 867, 867, + 867, 867, 867, 867, 867, 867, 867, 867, 867, 867, + 867, 867, 867, 867, 867, 867, 867, 867, 867, 867, + 867, 867, 867, 867, 867, 867, 867, 867, 867, 867, + 495, 486, -21, -21, 415, 668, 335, 619, 222, 511, + 213, 25, 25, 25, 25, 25, 148, 16, 4, 4, + 4, 4, 151, 312, 312, 312, 312, 119, 119, 119, + 119, 346, 346, 123, 245, 245, 349, 400, 297, 297, + 297, 297, 297, 297, 297, 297, 297, 297, 111, 558, + 558, 561, 561, 310, 152, 152, 152, 152, 704, 273, + 273, 129, 371, 371, 371, 373, 734, 797, 376, 376, + 376, 376, 376, 376, 468, 468, 468, 480, 480, 480, + 702, 587, 454, 587, 454, 684, 748, 509, 748, 700, + 199, 515, 803, 398, 720, 829, 729, 830, 601, 747, + 235, 782, 724, 419, 782, 633, 637, 634, 419, 419, + 715, 98, 863, 292, 195, 595, 405, 667, 781, 421, + 732, 784, 363, 445, 411, 593, 328, 286, 744, 785, + 888, 889, 181, 739, 667, 667, 667, 139, 362, 328, + -8, 613, 613, 613, 613, 48, 613, 613, 613, 613, + 314, 230, 506, 404, 783, 703, 703, 712, 694, 852, + 696, 696, 703, 711, 703, 712, 694, 854, 854, 854, + 854, 703, 694, 703, 703, 703, 696, 696, 694, 709, + 696, 38, 694, 695, 707, 707, 854, 751, 752, 703, + 703, 728, 696, 696, 696, 728, 694, 854, 685, 746, + 234, 696, 854, 665, 711, 665, 703, 685, 694, 665, + 711, 711, 665, 21, 662, 664, 853, 855, 869, 792, + 681, 716, 861, 862, 856, 860, 844, 679, 753, 754, + 569, 669, 671, 673, 699, 740, 701, 735, 724, 692, + 692, 692, 713, 741, 713, 692, 692, 692, 692, 692, + 692, 692, 692, 893, 689, 745, 736, 710, 755, 589, + 600, 793, 731, 738, 882, 875, 891, 892, 863, 880, + 713, 894, 697, 180, 650, 864, 693, 788, 713, 865, + 713, 794, 713, 883, 804, 708, 805, 806, 692, 884, + 895, 896, 897, 898, 899, 900, 901, 902, 706, 903, + 756, 698, 876, 339, 859, 715, 742, 725, 791, 759, + 807, 342, 904, 808, 713, 713, 795, 787, 713, 796, + 764, 750, 872, 766, 877, 905, 731, 726, 878, 713, + 730, 809, 906, 342, 672, 705, 737, 721, 767, 870, + 885, 868, 798, 655, 659, 810, 812, 820, 674, 769, + 873, 874, 871, 771, 799, 670, 800, 719, 821, 801, + 866, 772, 822, 823, 881, 718, 743, 717, 722, 714, + 802, 824, 879, 773, 774, 775, 827, 776, 828, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 136, 136, 136, - 136, -2, -2, -2, -2, 0, 0, -2, 0, 0, - 0, 136, 136, 136, 136, 136, 136, 136, 136, 136, - 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, - 136, 136, 136, 136, 136, 136, 136, 0, 0, 136, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 136, + 136, 136, 136, -2, -2, -2, -2, 0, 0, -2, + 0, 0, 0, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, + 136, 136, 136, 136, 136, 136, 136, 136, 136, 0, + 0, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, @@ -538,173 +540,164 @@ class Php5 extends \PhpParser\ParserAbstract 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, - 136, 575, 575, 575, 575, 575, 575, 575, 575, 575, - 575, 575, 575, 575, 575, 575, 575, 575, 575, 575, - 575, 575, 575, 575, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 575, -21, -21, -21, - -21, 575, -21, -21, -21, -21, -21, -21, -21, 575, - 575, 575, 575, 575, 575, 575, 575, 575, 575, 575, - 575, 575, 575, 575, 575, 575, 575, -21, 575, 575, - 575, -21, 101, -21, 101, 101, 101, 101, 101, 101, - 101, 101, 101, 101, 101, 101, 101, 101, 101, 101, - 101, 101, 101, 101, 101, 101, 101, 101, 101, 101, - 101, 101, 101, 101, 101, 101, 101, 101, 101, 101, - 101, 101, 101, 101, 101, 101, 101, 575, 0, 0, - 575, -21, 575, -21, 575, -21, 575, 575, 575, 575, - 575, 575, -21, -21, -21, -21, -21, -21, 0, 327, - 327, 327, 327, -21, -21, -21, -21, -37, 101, 101, - 101, 101, 101, 101, 327, 327, 452, 452, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 101, -37, - 101, 623, 623, 623, 623, 647, 647, 647, 623, 210, - 210, 210, 623, 0, 0, 0, 0, 0, 0, 623, - 210, 0, 101, 101, 101, 101, 0, 101, 101, 623, - 623, 623, 647, 623, 210, 647, 647, 623, 685, 583, - 583, 583, 583, 380, 363, 0, 623, 623, 647, 647, - 647, 0, 0, 0, 685, 0, 624, 0, 0, 0, - 0, 628, 230, 0, 528, 0, 0, 0, 0, 0, - 0, 643, 528, 592, 592, 0, 644, 628, 628, 628, - 0, 0, 643, 643, 0, 0, 0, 0, 0, 0, - 566, 643, 0, 0, 0, 0, 566, 517, 0, 0, - 517, 0, 380 + 136, 136, 136, 591, 591, 591, 591, 591, 591, 591, + 591, 591, 591, 591, 591, 591, 591, 591, 591, 591, + 591, 591, 591, 591, 591, 591, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 591, -21, + -21, -21, -21, 591, -21, -21, -21, -21, -21, -21, + -21, 591, 591, 591, 591, 591, 591, 591, 591, 591, + 591, 591, 591, 591, 591, 591, 591, 591, 591, -21, + 376, 591, 591, 591, -21, 376, 376, 376, 376, 376, + 376, 376, 376, 376, 376, 376, 376, 376, 376, 376, + 376, 376, 376, 376, 376, 376, 376, 376, 376, 376, + 376, 376, 376, 376, 376, 376, 376, 376, 376, 376, + 376, 376, 376, 376, 376, 376, 376, 376, -21, 591, + 0, 0, 591, -21, 591, -21, 591, -21, 591, 591, + 591, 591, 591, 591, -21, -21, -21, -21, -21, -21, + 0, 468, 468, 468, 468, -21, -21, -21, -21, 376, + 376, -37, 376, 376, 376, 376, 376, 376, 376, 376, + 376, 376, 376, 376, 376, 376, 376, 468, 468, 480, + 480, 376, 376, 376, 376, 376, -37, 376, 376, 419, + 711, 711, 711, 454, 454, 454, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 454, 419, + 0, 419, 0, 376, 419, 711, 419, 454, 711, 711, + 419, 696, 618, 618, 618, 618, 342, 328, 0, 711, + 711, 0, 711, 0, 0, 0, 0, 0, 696, 0, + 703, 0, 0, 0, 0, 692, 180, 0, 725, 427, + 0, 0, 0, 0, 0, 0, 725, 427, 435, 435, + 0, 706, 692, 692, 692, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 342 ); protected $actionDefault = array( 3,32767,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, - 32767,32767,32767,32767,32767, 533, 533, 488,32767,32767, + 32767,32767,32767,32767,32767, 534, 534, 489,32767,32767, 32767,32767,32767,32767,32767,32767,32767, 293, 293, 293, - 32767,32767,32767, 521, 521, 521, 521, 521, 521, 521, - 521, 521, 521, 521,32767,32767,32767,32767,32767, 376, - 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, + 32767,32767,32767, 522, 522, 522, 522, 522, 522, 522, + 522, 522, 522, 522,32767,32767,32767,32767,32767,32767, + 376,32767,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, - 32767,32767,32767,32767,32767,32767,32767, 382, 538,32767, + 32767,32767,32767,32767,32767,32767,32767,32767, 382, 539, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767, 357, 358, - 360, 361, 292, 541, 522, 241, 383, 537, 291, 243, - 321, 492,32767,32767,32767, 323, 120, 252, 197, 491, + 360, 361, 292, 542, 523, 241, 383, 538, 291, 243, + 321, 493,32767,32767,32767, 323, 120, 252, 197, 492, 123, 290, 228, 375, 377, 322, 297, 302, 303, 304, 305, 306, 307, 308, 309, 310, 311, 312, 313, 314, - 296, 448, 354, 353, 352, 450,32767, 449, 485, 485, - 488,32767,32767,32767,32767,32767,32767,32767,32767,32767, + 296, 449,32767, 354, 353, 352, 451, 486, 486, 489, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, - 32767, 319, 476, 475, 320, 446, 324, 447, 326, 451, - 325, 342, 343, 340, 341, 344, 453, 452, 469, 470, - 467, 468, 295, 345, 346, 347, 348, 471, 472, 473, - 474, 276,32767,32767, 532, 532,32767,32767, 333, 334, - 460, 461,32767,32767,32767,32767,32767,32767,32767,32767, - 32767,32767,32767, 277,32767, 232, 232, 232, 232,32767, - 32767,32767, 232,32767,32767,32767,32767, 328, 329, 327, - 455, 456, 454,32767, 422,32767,32767,32767,32767,32767, - 424,32767,32767,32767,32767,32767,32767,32767,32767,32767, - 32767,32767, 493,32767,32767,32767,32767,32767, 506, 411, - 32767,32767,32767, 404,32767, 216, 218, 165, 479,32767, - 32767,32767,32767,32767, 511, 338,32767,32767,32767,32767, - 32767, 548,32767, 506,32767,32767,32767,32767,32767,32767, - 351, 330, 331, 332,32767,32767,32767,32767, 510, 504, - 463, 464, 465, 466,32767,32767, 457, 458, 459, 462, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, - 32767,32767,32767,32767,32767,32767, 169,32767, 419, 425, - 425,32767,32767,32767,32767, 169,32767,32767,32767,32767, - 32767, 169,32767,32767,32767,32767, 509, 508, 169,32767, - 405, 487, 169, 182,32767, 180, 180,32767, 202, 202, - 32767,32767, 184, 480, 499,32767, 184, 169,32767, 393, - 171, 487,32767,32767, 234,32767, 234, 393, 169, 234, - 32767,32767, 234,32767, 85, 429,32767,32767,32767,32767, - 32767,32767,32767,32767,32767,32767,32767,32767, 406,32767, - 32767,32767, 372, 373, 482, 495,32767, 496,32767, 404, - 32767, 336, 337, 339, 316,32767, 318, 362, 363, 364, - 365, 366, 367, 368, 370,32767, 409,32767, 412,32767, - 32767,32767, 87, 112, 251,32767, 546, 87, 407,32767, - 32767, 300, 546,32767,32767,32767,32767, 540,32767,32767, - 294,32767,32767,32767, 87, 87, 247,32767, 167,32767, - 530,32767, 547,32767, 504, 408,32767, 335,32767,32767, - 32767,32767,32767,32767,32767,32767,32767, 505,32767,32767, - 32767,32767, 223,32767, 442,32767, 87,32767,32767, 183, - 32767,32767, 298, 242,32767,32767, 539,32767,32767,32767, - 32767,32767,32767,32767,32767,32767, 168,32767,32767,32767, - 185,32767,32767, 504,32767,32767,32767,32767,32767,32767, - 32767, 289,32767,32767,32767,32767,32767,32767,32767, 504, - 32767,32767, 227,32767,32767,32767,32767,32767,32767,32767, - 32767,32767, 85, 60,32767, 270,32767,32767,32767,32767, - 32767,32767,32767,32767,32767,32767,32767, 125, 125, 3, - 125, 125, 254, 3, 254, 125, 254, 254, 125, 125, - 125, 125, 125, 125, 125, 125, 125, 125, 210, 213, - 202, 202, 162, 125, 125, 262 + 450, 319, 477, 476, 320, 447, 324, 448, 326, 452, + 325, 342, 343, 340, 341, 344, 454, 453, 470, 471, + 468, 469, 295, 345, 346, 347, 348, 472, 473, 474, + 475,32767,32767, 276, 533, 533,32767,32767,32767,32767, + 32767,32767,32767,32767,32767,32767,32767,32767,32767, 333, + 334, 461, 462,32767, 232, 232, 232, 232, 277, 232, + 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, + 32767,32767,32767,32767, 328, 329, 327, 456, 457, 455, + 423,32767,32767,32767, 425,32767,32767,32767,32767,32767, + 32767,32767,32767, 494,32767,32767,32767,32767,32767, 507, + 412,32767, 404,32767,32767, 216, 218, 165,32767,32767, + 480,32767,32767,32767,32767,32767, 512, 338,32767,32767, + 114,32767,32767,32767, 549,32767, 507,32767, 114,32767, + 32767,32767,32767, 351, 330, 331, 332,32767,32767, 511, + 505, 464, 465, 466, 467,32767, 458, 459, 460, 463, + 32767,32767,32767,32767,32767,32767,32767,32767, 169, 420, + 426, 426,32767,32767,32767,32767, 169,32767,32767,32767, + 32767,32767, 169,32767,32767,32767, 510, 509, 169,32767, + 405, 488, 169, 182, 180, 180,32767, 202, 202,32767, + 32767, 184, 481, 500,32767, 184, 169,32767, 393, 171, + 488,32767,32767, 234,32767, 234,32767, 393, 169, 234, + 32767,32767, 234,32767, 406, 430,32767,32767,32767,32767, + 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, + 32767, 372, 373, 483, 496,32767, 497,32767, 404, 336, + 337, 339, 316,32767, 318, 362, 363, 364, 365, 366, + 367, 368, 370,32767, 410,32767, 413,32767,32767,32767, + 251,32767, 547,32767,32767, 300, 547,32767,32767,32767, + 541,32767,32767, 294,32767,32767,32767,32767, 247,32767, + 167,32767, 531,32767, 548,32767, 505,32767, 335,32767, + 32767,32767,32767,32767,32767,32767,32767,32767, 506,32767, + 32767,32767,32767, 223,32767, 443,32767, 114,32767,32767, + 32767, 183,32767,32767, 298, 242,32767,32767, 540,32767, + 32767,32767,32767,32767,32767,32767,32767, 112,32767, 168, + 32767,32767,32767, 185,32767,32767, 505,32767,32767,32767, + 32767,32767,32767,32767, 289,32767,32767,32767,32767,32767, + 32767,32767, 505,32767,32767, 227,32767,32767,32767,32767, + 32767,32767,32767,32767,32767, 406,32767, 270,32767,32767, + 32767,32767,32767,32767,32767,32767,32767,32767,32767, 125, + 125, 3, 125, 125, 254, 3, 254, 125, 254, 254, + 125, 125, 125, 125, 125, 125, 125, 125, 125, 125, + 210, 213, 202, 202, 162, 125, 125, 262 ); protected $goto = array( - 165, 138, 138, 138, 165, 143, 146, 139, 140, 141, + 165, 139, 139, 139, 165, 143, 146, 140, 141, 142, 148, 186, 167, 162, 162, 162, 162, 143, 143, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, 164, - 158, 159, 160, 161, 183, 137, 184, 501, 502, 365, - 503, 507, 508, 509, 510, 511, 512, 513, 514, 977, - 142, 163, 144, 145, 147, 170, 175, 185, 202, 251, + 137, 158, 159, 160, 161, 183, 138, 184, 489, 490, + 367, 491, 495, 496, 497, 498, 499, 500, 501, 502, + 959, 163, 144, 145, 147, 170, 175, 185, 203, 251, 254, 256, 258, 260, 261, 262, 263, 264, 265, 273, - 274, 275, 276, 288, 289, 317, 318, 319, 381, 382, - 383, 557, 187, 188, 189, 190, 191, 192, 193, 194, + 274, 275, 276, 299, 300, 324, 325, 326, 384, 385, + 386, 538, 187, 188, 189, 190, 191, 192, 193, 194, 195, 196, 197, 198, 199, 200, 149, 150, 151, 166, - 152, 168, 153, 203, 169, 154, 155, 156, 204, 157, - 135, 634, 575, 760, 575, 575, 575, 575, 575, 575, - 575, 575, 575, 575, 575, 575, 575, 575, 575, 575, - 575, 575, 575, 575, 575, 575, 575, 575, 575, 575, - 575, 575, 575, 575, 575, 575, 575, 575, 575, 575, - 575, 575, 575, 575, 575, 575, 575, 1116, 766, 1116, - 1116, 1116, 1116, 1116, 1116, 1116, 1116, 1116, 1116, 1116, - 1116, 1116, 1116, 1116, 1116, 1116, 1116, 1116, 1116, 1116, - 1116, 1116, 1116, 1116, 1116, 1116, 1116, 1116, 1116, 1116, - 1116, 1116, 1116, 1116, 1116, 1116, 1116, 1116, 1116, 1116, - 1116, 1116, 505, 505, 505, 505, 505, 505, 516, 642, - 516, 767, 505, 505, 505, 505, 505, 505, 505, 505, - 505, 505, 517, 797, 517, 898, 898, 1207, 1207, 531, - 589, 617, 862, 862, 862, 862, 173, 857, 863, 1092, - 1091, 176, 177, 178, 390, 391, 392, 393, 172, 201, - 205, 207, 255, 257, 259, 266, 267, 268, 269, 270, - 271, 277, 278, 279, 280, 290, 291, 320, 321, 322, - 396, 397, 398, 399, 174, 179, 252, 253, 180, 181, - 182, 389, 619, 550, 550, 582, 546, 598, 765, 613, - 614, 548, 548, 504, 506, 537, 554, 583, 586, 596, - 603, 884, 866, 864, 866, 668, 828, 519, 893, 888, - 574, 344, 574, 574, 574, 574, 574, 574, 574, 574, - 574, 574, 574, 574, 574, 574, 574, 574, 574, 574, - 574, 574, 574, 574, 574, 574, 574, 574, 574, 574, - 574, 574, 574, 574, 574, 574, 574, 574, 574, 574, - 574, 574, 574, 574, 574, 559, 560, 561, 562, 563, - 564, 565, 566, 568, 599, 522, 558, 330, 315, 1219, - 1219, 530, 592, 595, 640, 527, 527, 527, 868, 527, - 600, 347, 406, 530, 530, 1219, 440, 440, 440, 440, - 440, 440, 545, 527, 551, 954, 440, 440, 440, 440, - 440, 440, 440, 440, 440, 440, 1081, 1211, 1081, 905, - 905, 905, 905, 3, 4, 623, 905, 955, 626, 556, - 905, 363, 1185, 581, 1185, 916, 371, 371, 371, 366, - 1081, 1081, 1081, 1081, 790, 1081, 1081, 371, 371, 1184, - 607, 1184, 1177, 371, 1165, 471, 1201, 1201, 1201, 527, - 527, 371, 1233, 544, 576, 527, 527, 618, 1074, 527, - 1204, 790, 790, 378, 1025, 922, 524, 922, 518, 902, - 518, 911, 350, 1183, 975, 400, 528, 543, 786, 669, - 570, 372, 376, 920, 604, 784, 555, 895, 624, 625, - 891, 629, 630, 637, 639, 644, 646, 453, 455, 947, - 645, 673, 1097, 404, 1117, 627, 945, 1199, 1199, 1199, - 1035, 19, 15, 359, 1218, 1218, 1067, 872, 783, 783, - 794, 963, 791, 791, 791, 793, 1072, 925, 782, 456, - 1218, 569, 345, 346, 360, 524, 1077, 1078, 1221, 1162, - 1074, 535, 23, 587, 469, 547, 0, 615, 373, 373, - 373, 0, 0, 1075, 1176, 1075, 0, 0, 542, 0, - 460, 0, 1076, 0, 0, 0, 0, 0, 0, 0, - 0, 13, 0, 0, 0, 373, 0, 0, 622, 388, - 0, 0, 0, 1073, 631, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 521, 541, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 0, 521, - 0, 541, 0, 0, 0, 0, 0, 536, 520, 0, - 525, 443, 0, 445, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 789, 1226 + 152, 168, 153, 204, 169, 154, 155, 156, 205, 157, + 135, 616, 556, 574, 578, 622, 624, 556, 556, 556, + 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, + 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, + 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, + 556, 556, 556, 556, 556, 556, 556, 556, 556, 556, + 1099, 515, 345, 571, 600, 1099, 1099, 1099, 1099, 1099, + 1099, 1099, 1099, 1099, 1099, 1099, 1099, 1099, 1099, 1099, + 1099, 1099, 1099, 1099, 1099, 1099, 1099, 1099, 1099, 1099, + 1099, 1099, 1099, 1099, 1099, 1099, 1099, 1099, 1099, 1099, + 1099, 1099, 1099, 1099, 1099, 1099, 1099, 1099, 504, 1202, + 1202, 1075, 1074, 504, 540, 541, 542, 543, 544, 545, + 546, 547, 549, 582, 3, 4, 173, 1202, 844, 844, + 844, 844, 839, 845, 176, 177, 178, 391, 392, 393, + 394, 172, 201, 206, 250, 255, 257, 259, 266, 267, + 268, 269, 270, 271, 277, 278, 279, 280, 301, 302, + 327, 328, 329, 396, 397, 398, 399, 174, 179, 252, + 253, 180, 181, 182, 493, 493, 750, 493, 493, 493, + 493, 493, 493, 493, 493, 493, 493, 493, 493, 493, + 493, 505, 929, 442, 444, 627, 505, 751, 779, 1100, + 610, 927, 880, 880, 765, 1190, 1190, 1168, 555, 775, + 764, 743, 1168, 555, 555, 555, 555, 555, 555, 555, + 555, 555, 555, 555, 555, 555, 555, 555, 555, 555, + 555, 555, 555, 555, 555, 555, 555, 555, 555, 555, + 555, 555, 555, 555, 555, 555, 555, 555, 555, 555, + 555, 555, 555, 555, 555, 555, 390, 602, 746, 532, + 532, 564, 528, 530, 530, 492, 494, 520, 536, 565, + 568, 579, 586, 810, 606, 506, 346, 347, 609, 850, + 506, 365, 537, 746, 533, 746, 563, 430, 430, 375, + 430, 430, 430, 430, 430, 430, 430, 430, 430, 430, + 430, 430, 430, 430, 1063, 581, 957, 596, 597, 1063, + 887, 887, 887, 887, 1160, 887, 887, 1182, 1182, 1182, + 376, 376, 376, 749, 1063, 1063, 1063, 1063, 1063, 1063, + 334, 1056, 317, 374, 374, 374, 866, 848, 846, 848, + 650, 461, 507, 875, 870, 376, 1194, 368, 374, 389, + 374, 898, 374, 1080, 583, 348, 404, 374, 1216, 590, + 601, 1017, 19, 15, 361, 1148, 1187, 525, 936, 904, + 510, 526, 904, 651, 551, 381, 1201, 1201, 587, 1007, + 550, 877, 607, 608, 873, 612, 613, 619, 621, 626, + 628, 23, 884, 937, 1201, 336, 598, 1059, 1060, 1204, + 378, 1056, 557, 539, 893, 768, 766, 379, 514, 902, + 509, 524, 655, 1057, 1159, 1057, 776, 509, 1167, 524, + 514, 514, 1058, 1167, 1049, 907, 508, 1054, 511, 433, + 434, 510, 1184, 1184, 1184, 854, 445, 945, 569, 1145, + 459, 362, 0, 0, 773, 1209, 0, 518, 0, 519, + 0, 529, 0, 0, 0, 0, 0, 1166, 0, 0, + 0, 771, 0, 0, 0, 449, 0, 0, 0, 0, + 0, 0, 605, 0, 0, 0, 0, 13, 1055, 614 ); protected $gotoCheck = array( @@ -719,96 +712,89 @@ class Php5 extends \PhpParser\ParserAbstract 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, - 42, 56, 66, 5, 66, 66, 66, 66, 66, 66, + 42, 56, 66, 59, 59, 59, 8, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, - 66, 66, 66, 66, 66, 66, 66, 124, 14, 124, - 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, + 66, 66, 66, 66, 66, 66, 66, 66, 66, 66, + 124, 99, 69, 39, 39, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, - 124, 124, 115, 115, 115, 115, 115, 115, 66, 8, - 66, 15, 115, 115, 115, 115, 115, 115, 115, 115, - 115, 115, 115, 28, 115, 74, 74, 74, 74, 99, - 39, 39, 66, 66, 66, 66, 26, 66, 66, 122, - 122, 26, 26, 26, 26, 26, 26, 26, 26, 26, + 124, 124, 124, 124, 124, 124, 124, 124, 66, 140, + 140, 122, 122, 66, 108, 108, 108, 108, 108, 108, + 108, 108, 108, 108, 29, 29, 26, 140, 66, 66, + 66, 66, 66, 66, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, 26, - 26, 50, 50, 50, 50, 50, 50, 64, 13, 64, - 64, 50, 50, 50, 50, 50, 50, 50, 50, 50, - 50, 13, 13, 13, 13, 13, 49, 13, 13, 13, - 56, 69, 56, 56, 56, 56, 56, 56, 56, 56, + 26, 26, 26, 26, 115, 115, 14, 115, 115, 115, + 115, 115, 115, 115, 115, 115, 115, 115, 115, 115, + 115, 115, 7, 7, 7, 7, 115, 15, 28, 7, + 7, 7, 74, 74, 22, 74, 74, 116, 56, 22, + 22, 5, 116, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, - 56, 56, 56, 56, 56, 108, 108, 108, 108, 108, - 108, 108, 108, 108, 108, 10, 46, 123, 123, 140, - 140, 46, 59, 59, 59, 10, 10, 10, 32, 10, - 67, 67, 67, 46, 46, 140, 56, 56, 56, 56, - 56, 56, 10, 10, 107, 95, 56, 56, 56, 56, - 56, 56, 56, 56, 56, 56, 56, 138, 56, 56, - 56, 56, 56, 29, 29, 60, 56, 95, 60, 2, - 56, 60, 116, 2, 116, 81, 12, 12, 12, 45, - 56, 56, 56, 56, 22, 56, 56, 12, 12, 117, - 125, 117, 79, 12, 129, 56, 117, 117, 117, 10, - 10, 12, 12, 10, 10, 10, 10, 48, 79, 10, - 136, 22, 22, 47, 100, 12, 12, 12, 120, 76, - 120, 78, 17, 117, 99, 21, 10, 31, 24, 31, - 31, 11, 16, 82, 31, 23, 10, 31, 31, 31, - 31, 31, 31, 31, 31, 31, 31, 7, 7, 7, - 7, 71, 33, 20, 7, 7, 7, 8, 8, 8, - 33, 33, 33, 33, 139, 139, 111, 68, 22, 22, - 25, 97, 22, 22, 22, 22, 113, 83, 22, 62, - 139, 33, 69, 69, 57, 12, 79, 79, 139, 128, - 79, 57, 33, 63, 106, 57, -1, 33, 121, 121, - 121, -1, -1, 79, 79, 79, -1, -1, 8, -1, - 57, -1, 79, -1, -1, -1, -1, -1, -1, -1, - -1, 57, -1, -1, -1, 121, -1, -1, 12, 121, - -1, -1, -1, 12, 12, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 8, 8, -1, - -1, -1, -1, -1, -1, -1, -1, -1, -1, 8, - -1, 8, -1, -1, -1, -1, -1, 99, 8, -1, - 8, 8, -1, 8, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 8, 8 + 56, 56, 56, 56, 56, 56, 50, 50, 10, 50, + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 49, 60, 120, 69, 69, 60, 32, + 120, 60, 2, 10, 107, 10, 2, 56, 56, 10, + 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, + 56, 56, 56, 56, 56, 64, 99, 64, 64, 56, + 56, 56, 56, 56, 79, 56, 56, 8, 8, 8, + 121, 121, 121, 13, 56, 56, 56, 56, 56, 56, + 123, 79, 123, 12, 12, 12, 13, 13, 13, 13, + 13, 56, 13, 13, 13, 121, 138, 45, 12, 121, + 12, 81, 12, 33, 67, 67, 67, 12, 12, 125, + 48, 33, 33, 33, 33, 129, 136, 8, 95, 12, + 12, 31, 12, 31, 31, 47, 139, 139, 31, 100, + 33, 31, 31, 31, 31, 31, 31, 31, 31, 31, + 31, 33, 76, 95, 139, 17, 33, 79, 79, 139, + 11, 79, 11, 46, 78, 24, 23, 16, 46, 82, + 8, 8, 71, 79, 79, 79, 25, 8, 117, 8, + 46, 46, 79, 117, 111, 83, 8, 113, 8, 8, + 8, 12, 117, 117, 117, 68, 62, 97, 63, 128, + 106, 57, -1, -1, 8, 8, -1, 57, -1, 99, + -1, 57, -1, -1, -1, -1, -1, 117, -1, -1, + -1, 8, -1, -1, -1, 57, -1, -1, -1, -1, + -1, -1, 12, -1, -1, -1, -1, 57, 12, 12 ); protected $gotoBase = array( - 0, 0, -230, 0, 0, 102, 0, 492, 198, 0, - 42, 144, 113, 286, 156, 209, 132, 149, 0, 0, - 95, 141, 111, 134, 143, 99, 30, 0, 213, -260, - 0, -171, 358, 84, 0, 0, 0, 0, 0, 192, - 0, 0, -24, 0, 0, 389, 342, 170, 174, 288, - -1, 0, 0, 0, 0, 0, 104, 103, 0, 66, - -51, 0, 83, 87, -367, 0, -94, 53, 94, -138, - 0, 139, 0, 0, -57, 0, 157, 0, 155, 100, - 0, 397, 129, 105, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 114, 0, 97, 0, 188, - 160, 0, 0, 0, 0, 0, 77, 368, 311, 0, - 0, 96, 0, 101, 0, -80, 120, 137, 0, 0, - 166, 239, -71, 43, -49, 231, 0, 0, 78, 234, - 0, 0, 0, 0, 0, 0, 175, 0, 380, 200, - 55, 0, 0 + 0, 0, -249, 0, 0, 300, 0, 287, 105, 0, + 47, 164, 118, 421, 274, 295, 171, 184, 0, 0, + 0, 0, -49, 168, 172, 104, 24, 0, 288, -431, + 0, -159, 359, 44, 0, 0, 0, 0, 0, 125, + 0, 0, -24, 0, 0, 407, 479, 186, 178, 355, + 75, 0, 0, 0, 0, 0, 106, 119, 0, -192, + -81, 0, 101, 93, -231, 0, -90, 135, 121, -276, + 0, 148, 0, 0, 21, 0, 183, 0, 194, 71, + 0, 423, 155, 112, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 185, 0, 122, 0, 120, + 176, 0, 0, 0, 0, 0, 83, 358, 170, 0, + 0, 113, 0, 111, 0, -7, 9, 220, 0, 0, + 77, 108, -102, 100, -42, 251, 0, 0, 89, 256, + 0, 0, 0, 0, 0, 0, 181, 0, 419, 160, + -107, 0, 0 ); protected $gotoDefault = array( - -32768, 473, 677, 2, 678, 750, 758, 610, 487, 643, - 488, 523, 1195, 803, 804, 805, 368, 414, 489, 367, - 401, 394, 792, 785, 787, 795, 171, 402, 798, 1, - 800, 529, 836, 1026, 355, 808, 356, 602, 810, 539, - 812, 813, 136, 369, 370, 540, 490, 377, 590, 827, - 272, 374, 829, 357, 830, 839, 358, 470, 465, 571, - 621, 435, 452, 584, 578, 549, 1089, 579, 871, 343, - 879, 674, 887, 890, 491, 572, 901, 457, 909, 1102, - 384, 915, 921, 926, 281, 929, 415, 403, 597, 934, - 935, 7, 939, 635, 636, 8, 303, 962, 611, 976, - 420, 1045, 1047, 492, 493, 533, 464, 515, 538, 494, - 1068, 446, 405, 1071, 495, 496, 436, 437, 1086, 349, - 1170, 348, 454, 314, 1157, 593, 1121, 461, 1210, 1166, - 342, 497, 498, 364, 1189, 379, 1205, 441, 1212, 1220, - 338, 553, 580 + -32768, 463, 659, 2, 660, 733, 741, 593, 477, 625, + 577, 370, 1178, 785, 786, 787, 371, 358, 478, 369, + 400, 395, 774, 767, 769, 777, 171, 401, 780, 1, + 782, 513, 818, 1008, 355, 790, 356, 585, 792, 522, + 794, 795, 136, 372, 373, 523, 479, 380, 572, 809, + 272, 377, 811, 357, 812, 821, 360, 460, 454, 552, + 604, 425, 441, 566, 560, 531, 1072, 561, 853, 344, + 861, 656, 869, 872, 480, 553, 883, 446, 891, 1085, + 387, 897, 903, 908, 283, 911, 407, 402, 580, 916, + 917, 5, 921, 617, 618, 8, 308, 944, 594, 958, + 411, 1027, 1029, 481, 482, 517, 453, 503, 521, 483, + 1050, 435, 403, 1053, 484, 485, 426, 427, 1069, 350, + 1153, 349, 443, 316, 1140, 575, 1104, 450, 1193, 1149, + 343, 486, 487, 366, 1172, 382, 1188, 431, 1195, 1203, + 339, 535, 562 ); protected $ruleToNonTerminal = array( @@ -819,10 +805,10 @@ class Php5 extends \PhpParser\ParserAbstract 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, - 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, - 6, 7, 7, 8, 9, 10, 10, 11, 12, 4, - 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, - 17, 17, 18, 18, 18, 18, 20, 20, 16, 16, + 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, + 6, 6, 7, 7, 8, 9, 10, 10, 11, 11, + 12, 4, 4, 4, 4, 4, 4, 4, 4, 4, + 4, 4, 17, 17, 18, 18, 20, 20, 16, 16, 21, 21, 22, 22, 23, 23, 24, 24, 19, 19, 25, 27, 27, 28, 29, 29, 31, 30, 30, 30, 30, 32, 32, 32, 32, 32, 32, 32, 32, 32, @@ -852,22 +838,22 @@ class Php5 extends \PhpParser\ParserAbstract 42, 42, 42, 42, 42, 42, 42, 42, 42, 42, 33, 33, 46, 46, 103, 103, 104, 104, 104, 104, 110, 99, 99, 106, 106, 112, 112, 113, 114, 114, - 114, 114, 114, 114, 66, 66, 56, 56, 56, 100, - 100, 118, 118, 115, 115, 119, 119, 119, 119, 101, - 101, 101, 105, 105, 105, 111, 111, 124, 124, 124, + 114, 114, 114, 114, 66, 66, 56, 56, 56, 56, + 100, 100, 118, 118, 115, 115, 119, 119, 119, 119, + 101, 101, 101, 105, 105, 105, 111, 111, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, 124, - 26, 26, 26, 26, 26, 26, 126, 126, 126, 126, + 124, 26, 26, 26, 26, 26, 26, 126, 126, 126, + 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, 126, - 126, 126, 126, 126, 126, 126, 126, 126, 126, 109, - 109, 102, 102, 102, 102, 125, 125, 128, 128, 127, - 127, 129, 129, 50, 50, 50, 50, 131, 131, 130, - 130, 130, 130, 130, 132, 132, 117, 117, 120, 120, - 116, 116, 134, 133, 133, 133, 133, 121, 121, 121, - 121, 108, 108, 122, 122, 122, 122, 74, 135, 135, - 136, 136, 136, 107, 107, 137, 137, 138, 138, 138, - 138, 138, 123, 123, 123, 123, 140, 141, 139, 139, - 139, 139, 139, 139, 139, 142, 142, 142 + 109, 109, 102, 102, 102, 102, 125, 125, 128, 128, + 127, 127, 129, 129, 50, 50, 50, 50, 131, 131, + 130, 130, 130, 130, 130, 132, 132, 117, 117, 120, + 120, 116, 116, 134, 133, 133, 133, 133, 121, 121, + 121, 121, 108, 108, 122, 122, 122, 122, 74, 135, + 135, 136, 136, 136, 107, 107, 137, 137, 138, 138, + 138, 138, 138, 123, 123, 123, 123, 140, 141, 139, + 139, 139, 139, 139, 139, 139, 142, 142, 142 ); protected $ruleToLength = array( @@ -879,10 +865,10 @@ class Php5 extends \PhpParser\ParserAbstract 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 3, 1, 1, 1, - 1, 1, 1, 3, 5, 4, 3, 4, 2, 3, - 1, 1, 7, 8, 6, 7, 3, 1, 3, 1, - 3, 1, 1, 3, 1, 2, 1, 2, 3, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 3, 5, 4, 3, 4, + 2, 3, 1, 1, 7, 6, 3, 1, 3, 1, + 3, 1, 1, 3, 1, 3, 1, 2, 3, 1, 3, 3, 1, 3, 2, 0, 1, 1, 1, 1, 1, 3, 5, 8, 3, 5, 9, 3, 2, 3, 2, 3, 2, 3, 3, 3, 3, 1, 2, 2, @@ -911,22 +897,22 @@ class Php5 extends \PhpParser\ParserAbstract 2, 1, 1, 1, 3, 2, 1, 2, 10, 11, 3, 3, 2, 4, 4, 3, 4, 4, 4, 4, 7, 3, 2, 0, 4, 1, 3, 2, 2, 4, - 6, 2, 2, 4, 1, 1, 1, 2, 3, 1, - 1, 1, 1, 1, 1, 3, 3, 4, 4, 0, - 2, 1, 0, 1, 1, 0, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 3, 2, - 1, 3, 1, 4, 3, 1, 3, 3, 3, 3, + 6, 2, 2, 4, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 3, 3, 4, 4, + 0, 2, 1, 0, 1, 1, 0, 1, 1, 1, + 1, 1, 1, 1, 1, 1, 1, 1, 1, 3, + 2, 1, 3, 1, 4, 3, 1, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, - 3, 3, 3, 2, 2, 2, 2, 3, 3, 3, - 3, 3, 3, 3, 3, 5, 4, 4, 3, 1, - 3, 1, 1, 3, 3, 0, 2, 0, 1, 3, - 1, 3, 1, 1, 1, 1, 1, 6, 4, 3, - 4, 2, 4, 4, 1, 3, 1, 2, 1, 1, - 4, 1, 1, 3, 6, 4, 4, 4, 4, 1, - 4, 0, 1, 1, 3, 1, 1, 4, 3, 1, - 1, 1, 0, 0, 2, 3, 1, 3, 1, 4, - 2, 2, 2, 2, 1, 2, 1, 1, 1, 4, - 3, 3, 3, 6, 3, 1, 1, 1 + 3, 3, 3, 3, 2, 2, 2, 2, 3, 3, + 3, 3, 3, 3, 3, 3, 5, 4, 4, 3, + 1, 3, 1, 1, 3, 3, 0, 2, 0, 1, + 3, 1, 3, 1, 1, 1, 1, 1, 6, 4, + 3, 4, 2, 4, 4, 1, 3, 1, 2, 1, + 1, 4, 1, 1, 3, 6, 4, 4, 4, 4, + 1, 4, 0, 1, 1, 3, 1, 1, 4, 3, + 1, 1, 1, 0, 0, 2, 3, 1, 3, 1, + 4, 2, 2, 2, 2, 1, 2, 1, 1, 1, + 4, 3, 3, 3, 6, 3, 1, 1, 1 ); protected function initReduceCallbacks() { @@ -944,7 +930,7 @@ protected function initReduceCallbacks() { $this->semValue = array(); }, 4 => function ($stackPos) { - $startAttributes = $this->lookaheadStartAttributes; if (isset($startAttributes['comments'])) { $nop = new Stmt\Nop($this->createZeroLengthAttributes($startAttributes)); } else { $nop = null; }; + $startAttributes = $this->lookaheadStartAttributes; if (isset($startAttributes['comments'])) { $nop = new Stmt\Nop($this->createCommentNopAttributes($startAttributes['comments'])); } else { $nop = null; }; if ($nop !== null) { $this->semStack[$stackPos-(1-1)][] = $nop; } $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 5 => function ($stackPos) { @@ -1176,7 +1162,7 @@ protected function initReduceCallbacks() { $this->semValue = $this->semStack[$stackPos]; }, 81 => function ($stackPos) { - $this->semValue = new Node\Identifier($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos]; }, 82 => function ($stackPos) { $this->semValue = new Node\Identifier($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); @@ -1188,73 +1174,73 @@ protected function initReduceCallbacks() { $this->semValue = new Node\Identifier($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 85 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semValue = new Node\Identifier($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 86 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = new Name($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 87 => function ($stackPos) { $this->semValue = new Name($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 88 => function ($stackPos) { - $this->semValue = new Expr\Variable(substr($this->semStack[$stackPos-(1-1)], 1), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 89 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Name(substr($this->semStack[$stackPos-(1-1)], 1), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 90 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\Variable(substr($this->semStack[$stackPos-(1-1)], 1), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 91 => function ($stackPos) { $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 92 => function ($stackPos) { - $this->semValue = new Stmt\HaltCompiler($this->lexer->handleHaltCompiler(), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 93 => function ($stackPos) { + $this->semValue = $this->semStack[$stackPos-(1-1)]; + }, + 94 => function ($stackPos) { + $this->semValue = new Stmt\HaltCompiler($this->lexer->handleHaltCompiler(), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + }, + 95 => function ($stackPos) { $this->semValue = new Stmt\Namespace_($this->semStack[$stackPos-(3-2)], null, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); $this->semValue->setAttribute('kind', Stmt\Namespace_::KIND_SEMICOLON); $this->checkNamespace($this->semValue); }, - 94 => function ($stackPos) { + 96 => function ($stackPos) { $this->semValue = new Stmt\Namespace_($this->semStack[$stackPos-(5-2)], $this->semStack[$stackPos-(5-4)], $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes); $this->semValue->setAttribute('kind', Stmt\Namespace_::KIND_BRACED); $this->checkNamespace($this->semValue); }, - 95 => function ($stackPos) { + 97 => function ($stackPos) { $this->semValue = new Stmt\Namespace_(null, $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); $this->semValue->setAttribute('kind', Stmt\Namespace_::KIND_BRACED); $this->checkNamespace($this->semValue); }, - 96 => function ($stackPos) { - $this->semValue = new Stmt\Use_($this->semStack[$stackPos-(3-2)], Stmt\Use_::TYPE_NORMAL, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); - }, - 97 => function ($stackPos) { - $this->semValue = new Stmt\Use_($this->semStack[$stackPos-(4-3)], $this->semStack[$stackPos-(4-2)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); - }, 98 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = new Stmt\Use_($this->semStack[$stackPos-(3-2)], Stmt\Use_::TYPE_NORMAL, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 99 => function ($stackPos) { - $this->semValue = new Stmt\Const_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Stmt\Use_($this->semStack[$stackPos-(4-3)], $this->semStack[$stackPos-(4-2)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 100 => function ($stackPos) { - $this->semValue = Stmt\Use_::TYPE_FUNCTION; + $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 101 => function ($stackPos) { - $this->semValue = Stmt\Use_::TYPE_CONSTANT; + $this->semValue = new Stmt\Const_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 102 => function ($stackPos) { - $this->semValue = new Stmt\GroupUse(new Name($this->semStack[$stackPos-(7-3)], $this->startAttributeStack[$stackPos-(7-3)] + $this->endAttributeStack[$stackPos-(7-3)]), $this->semStack[$stackPos-(7-6)], $this->semStack[$stackPos-(7-2)], $this->startAttributeStack[$stackPos-(7-1)] + $this->endAttributes); + $this->semValue = Stmt\Use_::TYPE_FUNCTION; }, 103 => function ($stackPos) { - $this->semValue = new Stmt\GroupUse(new Name($this->semStack[$stackPos-(8-4)], $this->startAttributeStack[$stackPos-(8-4)] + $this->endAttributeStack[$stackPos-(8-4)]), $this->semStack[$stackPos-(8-7)], $this->semStack[$stackPos-(8-2)], $this->startAttributeStack[$stackPos-(8-1)] + $this->endAttributes); + $this->semValue = Stmt\Use_::TYPE_CONSTANT; }, 104 => function ($stackPos) { - $this->semValue = new Stmt\GroupUse(new Name($this->semStack[$stackPos-(6-2)], $this->startAttributeStack[$stackPos-(6-2)] + $this->endAttributeStack[$stackPos-(6-2)]), $this->semStack[$stackPos-(6-5)], Stmt\Use_::TYPE_UNKNOWN, $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); + $this->semValue = new Stmt\GroupUse($this->semStack[$stackPos-(7-3)], $this->semStack[$stackPos-(7-6)], $this->semStack[$stackPos-(7-2)], $this->startAttributeStack[$stackPos-(7-1)] + $this->endAttributes); }, 105 => function ($stackPos) { - $this->semValue = new Stmt\GroupUse(new Name($this->semStack[$stackPos-(7-3)], $this->startAttributeStack[$stackPos-(7-3)] + $this->endAttributeStack[$stackPos-(7-3)]), $this->semStack[$stackPos-(7-6)], Stmt\Use_::TYPE_UNKNOWN, $this->startAttributeStack[$stackPos-(7-1)] + $this->endAttributes); + $this->semValue = new Stmt\GroupUse($this->semStack[$stackPos-(6-2)], $this->semStack[$stackPos-(6-5)], Stmt\Use_::TYPE_UNKNOWN, $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); }, 106 => function ($stackPos) { $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; @@ -1281,10 +1267,10 @@ protected function initReduceCallbacks() { $this->semValue = new Stmt\UseUse($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], Stmt\Use_::TYPE_UNKNOWN, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); $this->checkUseUse($this->semValue, $stackPos-(3-3)); }, 114 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Stmt\UseUse($this->semStack[$stackPos-(1-1)], null, Stmt\Use_::TYPE_UNKNOWN, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); $this->checkUseUse($this->semValue, $stackPos-(1-1)); }, 115 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-2)]; + $this->semValue = new Stmt\UseUse($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], Stmt\Use_::TYPE_UNKNOWN, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); $this->checkUseUse($this->semValue, $stackPos-(3-3)); }, 116 => function ($stackPos) { $this->semValue = $this->semStack[$stackPos-(1-1)]; $this->semValue->type = Stmt\Use_::TYPE_NORMAL; @@ -1317,7 +1303,7 @@ protected function initReduceCallbacks() { $this->semValue = array(); }, 126 => function ($stackPos) { - $startAttributes = $this->lookaheadStartAttributes; if (isset($startAttributes['comments'])) { $nop = new Stmt\Nop($this->createZeroLengthAttributes($startAttributes)); } else { $nop = null; }; + $startAttributes = $this->lookaheadStartAttributes; if (isset($startAttributes['comments'])) { $nop = new Stmt\Nop($this->createCommentNopAttributes($startAttributes['comments'])); } else { $nop = null; }; if ($nop !== null) { $this->semStack[$stackPos-(1-1)][] = $nop; } $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 127 => function ($stackPos) { @@ -1715,7 +1701,7 @@ protected function initReduceCallbacks() { $this->semValue = array(); }, 255 => function ($stackPos) { - $startAttributes = $this->lookaheadStartAttributes; if (isset($startAttributes['comments'])) { $nop = new Stmt\Nop($this->createZeroLengthAttributes($startAttributes)); } else { $nop = null; }; + $startAttributes = $this->lookaheadStartAttributes; if (isset($startAttributes['comments'])) { $nop = new Stmt\Nop($this->createCommentNopAttributes($startAttributes['comments'])); } else { $nop = null; }; if ($nop !== null) { $this->semStack[$stackPos-(1-1)][] = $nop; } $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 256 => function ($stackPos) { @@ -2181,13 +2167,13 @@ protected function initReduceCallbacks() { $this->semValue = new Name($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 407 => function ($stackPos) { - $this->semValue = new Name\FullyQualified($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Name($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 408 => function ($stackPos) { - $this->semValue = new Name\Relative($this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Name\FullyQualified(substr($this->semStack[$stackPos-(1-1)], 1), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 409 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Name\Relative(substr($this->semStack[$stackPos-(1-1)], 10), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 410 => function ($stackPos) { $this->semValue = $this->semStack[$stackPos-(1-1)]; @@ -2205,243 +2191,243 @@ protected function initReduceCallbacks() { $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 415 => function ($stackPos) { - $this->semValue = new Expr\PropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 416 => function ($stackPos) { $this->semValue = new Expr\PropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 417 => function ($stackPos) { - $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = new Expr\PropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 418 => function ($stackPos) { $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 419 => function ($stackPos) { - $this->semValue = null; + $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 420 => function ($stackPos) { $this->semValue = null; }, 421 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = null; }, 422 => function ($stackPos) { - $this->semValue = array(); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 423 => function ($stackPos) { - $this->semValue = array(new Scalar\EncapsedStringPart(Scalar\String_::parseEscapeSequences($this->semStack[$stackPos-(1-1)], '`', false), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes)); + $this->semValue = array(); }, 424 => function ($stackPos) { - foreach ($this->semStack[$stackPos-(1-1)] as $s) { if ($s instanceof Node\Scalar\EncapsedStringPart) { $s->value = Node\Scalar\String_::parseEscapeSequences($s->value, '`', false); } }; $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = array(new Scalar\EncapsedStringPart(Scalar\String_::parseEscapeSequences($this->semStack[$stackPos-(1-1)], '`', false), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes)); }, 425 => function ($stackPos) { - $this->semValue = array(); + foreach ($this->semStack[$stackPos-(1-1)] as $s) { if ($s instanceof Node\Scalar\EncapsedStringPart) { $s->value = Node\Scalar\String_::parseEscapeSequences($s->value, '`', false); } }; $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 426 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = array(); }, 427 => function ($stackPos) { - $this->semValue = $this->parseLNumber($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes, true); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 428 => function ($stackPos) { - $this->semValue = new Scalar\DNumber(Scalar\DNumber::parse($this->semStack[$stackPos-(1-1)]), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = $this->parseLNumber($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes, true); }, 429 => function ($stackPos) { - $attrs = $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes; $attrs['kind'] = ($this->semStack[$stackPos-(1-1)][0] === "'" || ($this->semStack[$stackPos-(1-1)][1] === "'" && ($this->semStack[$stackPos-(1-1)][0] === 'b' || $this->semStack[$stackPos-(1-1)][0] === 'B')) ? Scalar\String_::KIND_SINGLE_QUOTED : Scalar\String_::KIND_DOUBLE_QUOTED); - $this->semValue = new Scalar\String_(Scalar\String_::parse($this->semStack[$stackPos-(1-1)], false), $attrs); + $this->semValue = new Scalar\DNumber(Scalar\DNumber::parse($this->semStack[$stackPos-(1-1)]), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 430 => function ($stackPos) { - $this->semValue = new Scalar\MagicConst\Line($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $attrs = $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes; $attrs['kind'] = ($this->semStack[$stackPos-(1-1)][0] === "'" || ($this->semStack[$stackPos-(1-1)][1] === "'" && ($this->semStack[$stackPos-(1-1)][0] === 'b' || $this->semStack[$stackPos-(1-1)][0] === 'B')) ? Scalar\String_::KIND_SINGLE_QUOTED : Scalar\String_::KIND_DOUBLE_QUOTED); + $this->semValue = new Scalar\String_(Scalar\String_::parse($this->semStack[$stackPos-(1-1)], false), $attrs); }, 431 => function ($stackPos) { - $this->semValue = new Scalar\MagicConst\File($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Scalar\MagicConst\Line($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 432 => function ($stackPos) { - $this->semValue = new Scalar\MagicConst\Dir($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Scalar\MagicConst\File($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 433 => function ($stackPos) { - $this->semValue = new Scalar\MagicConst\Class_($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Scalar\MagicConst\Dir($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 434 => function ($stackPos) { - $this->semValue = new Scalar\MagicConst\Trait_($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Scalar\MagicConst\Class_($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 435 => function ($stackPos) { - $this->semValue = new Scalar\MagicConst\Method($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Scalar\MagicConst\Trait_($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 436 => function ($stackPos) { - $this->semValue = new Scalar\MagicConst\Function_($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Scalar\MagicConst\Method($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 437 => function ($stackPos) { - $this->semValue = new Scalar\MagicConst\Namespace_($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Scalar\MagicConst\Function_($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 438 => function ($stackPos) { - $this->semValue = $this->parseDocString($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-2)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes, $this->startAttributeStack[$stackPos-(3-3)] + $this->endAttributeStack[$stackPos-(3-3)], false); + $this->semValue = new Scalar\MagicConst\Namespace_($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 439 => function ($stackPos) { - $this->semValue = $this->parseDocString($this->semStack[$stackPos-(2-1)], '', $this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes, $this->startAttributeStack[$stackPos-(2-2)] + $this->endAttributeStack[$stackPos-(2-2)], false); + $this->semValue = $this->parseDocString($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-2)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes, $this->startAttributeStack[$stackPos-(3-3)] + $this->endAttributeStack[$stackPos-(3-3)], false); }, 440 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = $this->parseDocString($this->semStack[$stackPos-(2-1)], '', $this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes, $this->startAttributeStack[$stackPos-(2-2)] + $this->endAttributeStack[$stackPos-(2-2)], false); }, 441 => function ($stackPos) { - $this->semValue = new Expr\ClassConstFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 442 => function ($stackPos) { - $this->semValue = new Expr\ConstFetch($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Expr\ClassConstFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 443 => function ($stackPos) { - $this->semValue = new Expr\Array_($this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = new Expr\ConstFetch($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 444 => function ($stackPos) { - $this->semValue = new Expr\Array_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\Array_($this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 445 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\Array_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 446 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\BooleanOr($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 447 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\BooleanAnd($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\BooleanOr($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 448 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\LogicalOr($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\BooleanAnd($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 449 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\LogicalAnd($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\LogicalOr($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 450 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\LogicalXor($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\LogicalAnd($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 451 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\BitwiseOr($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\LogicalXor($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 452 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\BitwiseAnd($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\BitwiseOr($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 453 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\BitwiseXor($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\BitwiseAnd($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 454 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Concat($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\BitwiseXor($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 455 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Plus($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Concat($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 456 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Minus($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Plus($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 457 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Mul($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Minus($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 458 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Div($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Mul($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 459 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Mod($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Div($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 460 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\ShiftLeft($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Mod($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 461 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\ShiftRight($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\ShiftLeft($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 462 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Pow($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\ShiftRight($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 463 => function ($stackPos) { - $this->semValue = new Expr\UnaryPlus($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Pow($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 464 => function ($stackPos) { - $this->semValue = new Expr\UnaryMinus($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\UnaryPlus($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 465 => function ($stackPos) { - $this->semValue = new Expr\BooleanNot($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\UnaryMinus($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 466 => function ($stackPos) { - $this->semValue = new Expr\BitwiseNot($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\BooleanNot($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 467 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Identical($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BitwiseNot($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 468 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\NotIdentical($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Identical($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 469 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Equal($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\NotIdentical($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 470 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\NotEqual($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Equal($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 471 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Smaller($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\NotEqual($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 472 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\SmallerOrEqual($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Smaller($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 473 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Greater($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\SmallerOrEqual($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 474 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\GreaterOrEqual($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Greater($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 475 => function ($stackPos) { - $this->semValue = new Expr\Ternary($this->semStack[$stackPos-(5-1)], $this->semStack[$stackPos-(5-3)], $this->semStack[$stackPos-(5-5)], $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\GreaterOrEqual($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 476 => function ($stackPos) { - $this->semValue = new Expr\Ternary($this->semStack[$stackPos-(4-1)], null, $this->semStack[$stackPos-(4-4)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = new Expr\Ternary($this->semStack[$stackPos-(5-1)], $this->semStack[$stackPos-(5-3)], $this->semStack[$stackPos-(5-5)], $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes); }, 477 => function ($stackPos) { - $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = new Expr\Ternary($this->semStack[$stackPos-(4-1)], null, $this->semStack[$stackPos-(4-4)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 478 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(3-2)]; + $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 479 => function ($stackPos) { - $this->semValue = new Expr\ConstFetch($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(3-2)]; }, 480 => function ($stackPos) { - $this->semValue = new Expr\ClassConstFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\ConstFetch($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 481 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\ClassConstFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 482 => function ($stackPos) { $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 483 => function ($stackPos) { - $attrs = $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes; $attrs['kind'] = Scalar\String_::KIND_DOUBLE_QUOTED; - foreach ($this->semStack[$stackPos-(3-2)] as $s) { if ($s instanceof Node\Scalar\EncapsedStringPart) { $s->value = Node\Scalar\String_::parseEscapeSequences($s->value, '"', true); } }; $this->semValue = new Scalar\Encapsed($this->semStack[$stackPos-(3-2)], $attrs); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 484 => function ($stackPos) { - $this->semValue = $this->parseDocString($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-2)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes, $this->startAttributeStack[$stackPos-(3-3)] + $this->endAttributeStack[$stackPos-(3-3)], true); + $attrs = $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes; $attrs['kind'] = Scalar\String_::KIND_DOUBLE_QUOTED; + foreach ($this->semStack[$stackPos-(3-2)] as $s) { if ($s instanceof Node\Scalar\EncapsedStringPart) { $s->value = Node\Scalar\String_::parseEscapeSequences($s->value, '"', true); } }; $this->semValue = new Scalar\Encapsed($this->semStack[$stackPos-(3-2)], $attrs); }, 485 => function ($stackPos) { - $this->semValue = array(); + $this->semValue = $this->parseDocString($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-2)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes, $this->startAttributeStack[$stackPos-(3-3)] + $this->endAttributeStack[$stackPos-(3-3)], true); }, 486 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = array(); }, 487 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos]; + $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 488 => function ($stackPos) { $this->semValue = $this->semStack[$stackPos]; }, 489 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = $this->semStack[$stackPos]; }, 490 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 491 => function ($stackPos) { - $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(3-3)], $this->semStack[$stackPos-(3-1)], false, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 492 => function ($stackPos) { - $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(1-1)], null, false, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(3-3)], $this->semStack[$stackPos-(3-1)], false, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 493 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(1-1)], null, false, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 494 => function ($stackPos) { $this->semValue = $this->semStack[$stackPos-(1-1)]; @@ -2453,61 +2439,61 @@ protected function initReduceCallbacks() { $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 497 => function ($stackPos) { - $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(6-2)], $this->semStack[$stackPos-(6-5)], $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 498 => function ($stackPos) { - $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(6-2)], $this->semStack[$stackPos-(6-5)], $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); }, 499 => function ($stackPos) { - $this->semValue = new Expr\PropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 500 => function ($stackPos) { - $this->semValue = new Expr\MethodCall($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->semStack[$stackPos-(4-4)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = new Expr\PropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 501 => function ($stackPos) { - $this->semValue = new Expr\FuncCall($this->semStack[$stackPos-(2-1)], $this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\MethodCall($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->semStack[$stackPos-(4-4)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 502 => function ($stackPos) { - $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = new Expr\FuncCall($this->semStack[$stackPos-(2-1)], $this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 503 => function ($stackPos) { $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 504 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 505 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(3-2)]; + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 506 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = $this->semStack[$stackPos-(3-2)]; }, 507 => function ($stackPos) { - $this->semValue = new Expr\Variable($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 508 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\Variable($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 509 => function ($stackPos) { $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 510 => function ($stackPos) { - $this->semValue = new Expr\StaticPropertyFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-4)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 511 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\StaticPropertyFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-4)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 512 => function ($stackPos) { - $var = substr($this->semStack[$stackPos-(1-1)], 1); $this->semValue = \is_string($var) ? new Node\VarLikeIdentifier($var, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes) : $var; + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 513 => function ($stackPos) { - $this->semValue = new Expr\StaticPropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $var = substr($this->semStack[$stackPos-(1-1)], 1); $this->semValue = \is_string($var) ? new Node\VarLikeIdentifier($var, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes) : $var; }, 514 => function ($stackPos) { - $this->semValue = new Expr\StaticPropertyFetch($this->semStack[$stackPos-(6-1)], $this->semStack[$stackPos-(6-5)], $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); + $this->semValue = new Expr\StaticPropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 515 => function ($stackPos) { - $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = new Expr\StaticPropertyFetch($this->semStack[$stackPos-(6-1)], $this->semStack[$stackPos-(6-5)], $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); }, 516 => function ($stackPos) { $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); @@ -2519,120 +2505,123 @@ protected function initReduceCallbacks() { $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 519 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 520 => function ($stackPos) { - $this->semValue = new Expr\Variable($this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 521 => function ($stackPos) { - $this->semValue = null; + $this->semValue = new Expr\Variable($this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 522 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = null; }, 523 => function ($stackPos) { $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 524 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(3-2)]; + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 525 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = $this->semStack[$stackPos-(3-2)]; }, 526 => function ($stackPos) { - $this->semValue = new Expr\Error($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); $this->errorState = 2; + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 527 => function ($stackPos) { - $this->semValue = new Expr\List_($this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = new Expr\Error($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); $this->errorState = 2; }, 528 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = new Expr\List_($this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 529 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 530 => function ($stackPos) { - $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(1-1)], null, false, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 531 => function ($stackPos) { $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(1-1)], null, false, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 532 => function ($stackPos) { - $this->semValue = null; + $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(1-1)], null, false, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 533 => function ($stackPos) { - $this->semValue = array(); + $this->semValue = null; }, 534 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = array(); }, 535 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 536 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 537 => function ($stackPos) { - $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(3-3)], $this->semStack[$stackPos-(3-1)], false, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 538 => function ($stackPos) { - $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(1-1)], null, false, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(3-3)], $this->semStack[$stackPos-(3-1)], false, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 539 => function ($stackPos) { - $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(4-4)], $this->semStack[$stackPos-(4-1)], true, $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(1-1)], null, false, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 540 => function ($stackPos) { - $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(2-2)], null, true, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(4-4)], $this->semStack[$stackPos-(4-1)], true, $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 541 => function ($stackPos) { - $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(2-2)], null, false, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes, true, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(2-2)], null, true, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 542 => function ($stackPos) { - $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(2-2)], null, false, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes, true, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 543 => function ($stackPos) { $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 544 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 545 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(2-1)], $this->semStack[$stackPos-(2-2)]); + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 546 => function ($stackPos) { - $this->semValue = new Scalar\EncapsedStringPart($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = array($this->semStack[$stackPos-(2-1)], $this->semStack[$stackPos-(2-2)]); }, 547 => function ($stackPos) { - $this->semValue = new Expr\Variable($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Scalar\EncapsedStringPart($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 548 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\Variable($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 549 => function ($stackPos) { - $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 550 => function ($stackPos) { - $this->semValue = new Expr\PropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 551 => function ($stackPos) { - $this->semValue = new Expr\Variable($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\PropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 552 => function ($stackPos) { $this->semValue = new Expr\Variable($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 553 => function ($stackPos) { - $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(6-2)], $this->semStack[$stackPos-(6-4)], $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); + $this->semValue = new Expr\Variable($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 554 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(3-2)]; + $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(6-2)], $this->semStack[$stackPos-(6-4)], $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); }, 555 => function ($stackPos) { - $this->semValue = new Scalar\String_($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(3-2)]; }, 556 => function ($stackPos) { - $this->semValue = $this->parseNumString($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Scalar\String_($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 557 => function ($stackPos) { + $this->semValue = $this->parseNumString($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + }, + 558 => function ($stackPos) { $this->semValue = $this->semStack[$stackPos-(1-1)]; }, ]; diff --git a/nikic/php-parser/lib/PhpParser/Parser/Php7.php b/nikic/php-parser/lib/PhpParser/Parser/Php7.php index f250ede0c..55d16585b 100644 --- a/nikic/php-parser/lib/PhpParser/Parser/Php7.php +++ b/nikic/php-parser/lib/PhpParser/Parser/Php7.php @@ -17,21 +17,22 @@ */ class Php7 extends \PhpParser\ParserAbstract { - protected $tokenToSymbolMapSize = 394; - protected $actionTableSize = 966; - protected $gotoTableSize = 527; + protected $tokenToSymbolMapSize = 392; + protected $actionTableSize = 1162; + protected $gotoTableSize = 588; - protected $invalidSymbol = 159; + protected $invalidSymbol = 165; protected $errorSymbol = 1; protected $defaultAction = -32766; protected $unexpectedTokenRule = 32767; - protected $YY2TBLSTATE = 350; - protected $numNonLeafStates = 606; + protected $YY2TBLSTATE = 397; + protected $numNonLeafStates = 688; protected $symbolToName = array( "EOF", "error", + "T_THROW", "T_INCLUDE", "T_INCLUDE_ONCE", "T_EVAL", @@ -127,6 +128,7 @@ class Php7 extends \PhpParser\ParserAbstract "T_ENDDECLARE", "T_AS", "T_SWITCH", + "T_MATCH", "T_ENDSWITCH", "T_CASE", "T_DEFAULT", @@ -140,7 +142,6 @@ class Php7 extends \PhpParser\ParserAbstract "T_TRY", "T_CATCH", "T_FINALLY", - "T_THROW", "T_USE", "T_INSTEADOF", "T_GLOBAL", @@ -161,6 +162,7 @@ class Php7 extends \PhpParser\ParserAbstract "T_EXTENDS", "T_IMPLEMENTS", "T_OBJECT_OPERATOR", + "T_NULLSAFE_OBJECT_OPERATOR", "T_LIST", "T_ARRAY", "T_CALLABLE", @@ -180,571 +182,650 @@ class Php7 extends \PhpParser\ParserAbstract "T_DIR", "T_NS_SEPARATOR", "T_ELLIPSIS", + "T_NAME_FULLY_QUALIFIED", + "T_NAME_QUALIFIED", + "T_NAME_RELATIVE", + "T_ATTRIBUTE", "';'", + "']'", "'{'", "'}'", "'('", "')'", "'`'", - "']'", "'\"'", "'$'" ); protected $tokenToSymbol = array( - 0, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 54, 157, 159, 158, 53, 36, 159, - 153, 154, 51, 48, 7, 49, 50, 52, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 30, 150, - 42, 15, 44, 29, 66, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 68, 159, 156, 35, 159, 155, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 151, 34, 152, 56, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, - 159, 159, 159, 159, 159, 159, 1, 2, 3, 4, - 5, 6, 8, 9, 10, 11, 12, 13, 14, 16, + 0, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 55, 163, 165, 164, 54, 37, 165, + 160, 161, 52, 49, 8, 50, 51, 53, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 31, 156, + 43, 16, 45, 30, 67, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 69, 165, 157, 36, 165, 162, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 158, 35, 159, 57, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 165, 165, 165, 165, + 165, 165, 165, 165, 165, 165, 1, 2, 3, 4, + 5, 6, 7, 9, 10, 11, 12, 13, 14, 15, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, - 27, 28, 31, 32, 33, 37, 38, 39, 40, 41, - 43, 45, 46, 47, 55, 57, 58, 59, 60, 61, - 62, 63, 64, 65, 67, 69, 70, 71, 72, 73, - 74, 75, 76, 77, 78, 79, 80, 81, 82, 159, - 159, 83, 84, 85, 86, 87, 88, 89, 90, 91, - 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, - 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, - 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, - 122, 123, 124, 125, 126, 127, 128, 129, 130, 131, - 132, 133, 134, 135, 136, 137, 138, 139, 159, 159, - 159, 159, 159, 159, 140, 141, 142, 143, 144, 145, - 146, 147, 148, 149 + 27, 28, 29, 32, 33, 34, 38, 39, 40, 41, + 42, 44, 46, 47, 48, 56, 58, 59, 60, 61, + 62, 63, 64, 65, 66, 68, 70, 71, 72, 73, + 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, + 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, + 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, + 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, + 114, 115, 116, 117, 118, 119, 120, 121, 122, 123, + 124, 125, 126, 127, 128, 129, 130, 131, 132, 133, + 134, 135, 136, 137, 138, 139, 140, 141, 142, 143, + 144, 145, 146, 147, 148, 149, 150, 151, 152, 153, + 154, 155 ); protected $action = array( - 611, 612, 613, 614, 615, 689, 616, 617, 618, 654, - 655, 0, 32, 103, 104, 105, 106, 107, 108, 109, - 110, 111, 112, 113, 114, 115,-32767,-32767,-32767,-32767, - 94, 95, 96, 97, 98,-32766,-32766,-32766, 691, 493, - -500, 911, 912, 913, 910, 909, 908, 911, 912, 913, - 910, 909, 908, 619, 945, 947,-32766, 9,-32766,-32766, - -32766,-32766,-32766,-32766,-32766,-32766,-32766, 620, 621, 622, - 623, 624, 625, 626, 335, 1111, 687,-32766,-32766,-32766, - 850, 1110, 119, 627, 628, 629, 630, 631, 632, 633, - 634, 635, 636, 637, 657, 658, 659, 660, 661, 649, - 650, 651, 679, 652, 653, 638, 639, 640, 641, 642, - 643, 644, 681, 682, 683, 684, 685, 686, 645, 646, - 647, 648, 678, 669, 667, 668, 664, 665, 404, 656, - 662, 663, 670, 671, 673, 672, 674, 675, 45, 46, - 423, 47, 48, 666, 677, 676, 27, 49, 50, 233, - 51,-32766,-32766,-32766, 96, 97, 98, 24,-32766,-32766, - -32766, -461, 261, 121, 1030,-32766,-32766,-32766, 1098, 1080, - -32766,-32766,-32766, 1046,-32766,-32766,-32766,-32766,-32766,-32766, - -499,-32766,-32766,-32766, 52, 53,-32766, -500,-32766,-32766, - 54, 691, 55, 231, 232, 56, 57, 58, 59, 60, - 61, 62, 63, 1023, 24, 242, 64, 371,-32766,-32766, - -32766, 226, 1047, 1048, 425, 1083, 1080, -496, 887, 512, - 1046, 438, 1030, -461, 772, 1080, 239, 335, -503,-32766, - -503,-32766,-32766,-32766,-32766, 863, 252, -461, 278, 380, - 374, 790, 68, 1080, -461, 689, -464, 280, 1133, 405, - 291, 1134, 290, 99, 100, 101, 305, 253, 435, 436, - 826,-32766, 69, 261, 237, 855, 856, 437, 438, 102, - 1052, 1053, 1054, 1055, 1049, 1050, 256, 1023, -459, -459, - 308, 446, 1056, 1051, 377, 133, 565, -239, 365, 66, - 237, 270, 696, 275, 280, 424, -137, -137, -137, -4, - 772, 1080, 312, 280, 1042, 761, 691, 364, 37, 20, - 426, -137, 427, -137, 428, -137, 429, -137, 127, 430, - -298, 280, -298, 38, 39, 372, 373, -499, 273, 40, - 431, 279, 691, 65, 261, 1023, 304, 903, 432, 433, - -459, -459, 335, -497, 434, 44, 42, 747, 795, 375, - 376, -460, -234, 566, -459, -459, 377,-32766,-32766,-32766, - 889, -459, -459, 124, -496, 75, 855, 856, 335, -276, - -263, 424, 772, 774, 580, -137, 261, 125,-32766, 280, - 827, 761, 864, 1080, 37, 20, 426, 240, 427, -178, - 428, 593, 429, 395, 505, 430, 691, 235, 241, 38, - 39, 372, 373, 125, 356, 40, 431, 260, 259, 65, - 269, 691, 304, -460, 432, 433, -299, -177, -299, 24, - 434, 307, 367, 704, 795, 375, 376, -460, 120, 118, - 24, 1080, 30, 368, -460, 1046, -463, 855, 856, 691, - 369, 695, 1080, 424, 293, 772, 1046, 335, -83, 774, - 580, -4, 469, 761, 126, 370, 37, 20, 426, -92, - 427, 280, 428, 446, 429, 1023, 377, 430, -219, -219, - -219, 38, 39, 372, 373, 335, 1023, 40, 431, 855, - 856, 65, 437, 438, 304, 236, 432, 433, 225, 712, - -497, 713, 434, 437, 438, 747, 795, 375, 376, 694, - 389, 136, 1124, 582, 68, 415, 238, 8, 33, 280, - 1060, 227, 712, 691, 713, 68, 424, -263, 539, 21, - 280, 774, 580, -219, 554, 555, 761, 691, 116, 37, - 20, 426, 117, 427, 360, 428, -178, 429, 132, 330, - 430, -218, -218, -218, 38, 39, 372, 373, 691, 335, - 40, 431, 122, 772, 65, 385, 386, 304, 123, 432, - 433, 29, 234, 335, -177, 434, 532, 533, 747, 795, - 375, 376, 129, 855, 856, 135, 76, 77, 78, 1099, - 888, 603, 586, 254, 335, 137, 138, 786, 594, 597, - 262, 771, 131, 253, 774, 580, -218, 31, 263, 79, - 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, - 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, - 100, 101, 295, 253, 424, 562, 772, 691, 694,-32766, - 102, 478, 689, 43, 761, 102, 1135, 37, 20, 426, - 130, 427, -81, 428, 692, 429, 530, 917, 430, 796, - 1023, 274, 38, 39, 372, 587, 473, 540, 40, 431, - 271, 277, 65, 272, 574, 304, 797, 557, 1059, 1062, - 545, 338, 772, 434, 10, 393, 35, 344, 546, 558, - 788, 581, 1061, 0, -418, 0, 5, 0, 0, 12, - 0, 0, 0, 0, 0, 0, 0, 424, 0, 0, - 0, 588, 774, 580, 0, 0, 0, 761, 0, 0, - 37, 20, 426, 0, 427, 0, 428, 0, 429, 772, - 0, 430, 306, 0, 0, 38, 39, 372, 583, 0, - 0, 40, 431, 345, 349, 65, 598, 389, 304, 475, - 361, 362, 748, 424, 36, 601, 434, 602, 591, 752, - 829, 813, 820, 761, 883, 884, 37, 20, 426, 810, - 427, 821, 428, 750, 429, 772, 808, 430, 892, 895, - 896, 38, 39, 372, 893, 774, 580, 40, 431, 894, - 900, 65, 585, 589, 304, 590, 592, 596, 288, 289, - 424, 354, 434, 355, 595, 584, -488, 1130, 1132, 707, - 761, 794, 706, 37, 20, 426, 716, 427, 793, 428, - 717, 429, 772, 714, 430, 1131, 792, 1011, 38, 39, - 372, 812, 580, -486, 40, 431, 715, 781, 65, 789, - 779, 304, 818, 819, 1129, 1081, 424, 1074, 1088, 434, - 1093, 1096, -430, -464, -463, -462, 761, 23, 25, 37, - 20, 426, 28, 427, 34, 428, 41, 429, 67, 70, - 430, 71, 72, 73, 38, 39, 372, 74, 774, 580, - 40, 431, 128, 134, 65, 139, 229, 304, 230, 246, - 247, 248, 249, 424, 250, 434, 251, 292, 357, 359, - 0, -237, -235, 761, -234, 14, 37, 20, 426, 15, - 427, 16, 428, 17, 429, 19, 327, 430, 406, 408, - 411, 38, 39, 372, 774, 580, 413, 40, 431, 414, - 421, 65, 571, 1034, 304,-32766,-32766,-32766, 984, 1044, - 865, 1015, 434, -92, 13, 18, 22, 265, 326, 503, - 526, 573, 988, 985, 0, 1001,-32766, 1043,-32766,-32766, - -32766,-32766,-32766,-32766,-32767,-32767,-32767,-32767,-32767, 1072, - 1073, 774, 580, 1087, 1127, 536 + 130, 131, 132, 552, 133, 134, 0, 698, 699, 700, + 135, 36, 883, 528, 529,-32766, 1212,-32766,-32766,-32766, + -551, 1145, 772, 889, 430, 431, 1232, -551,-32766,-32766, + -32766, -293,-32766, 1231,-32766, 245,-32766, -189,-32766,-32766, + -32766,-32766,-32766, 458,-32766,-32766,-32766,-32766,-32766,-32766, + -32766,-32766, 124, 783, 701, 777,-32766, 388, 1024, 1025, + 1026, 1023, 1022, 1021,-32766, 428, 429, 955, 261, 136, + 372, 705, 706, 707, 708, 391, -188, 397, 1024, 1025, + 1026, 1023, 1022, 1021, 709, 710, 711, 712, 713, 714, + 715, 716, 717, 718, 719, 739, 553, 740, 741, 742, + 743, 731, 732, 373, 374, 734, 735, 720, 721, 722, + 724, 725, 726, 333, 765, 766, 767, 768, 769, 727, + 728, 554, 555, 760, 751, 749, 750, 746, 747, 778, + 2, 556, 557, 745, 558, 559, 560, 561, 562, 563, + -542, -548, 19, -502, -542, 748, 564, 565, -548, 137, + -32766,-32766,-32766, 130, 131, 132, 552, 133, 134, 976, + 698, 699, 700, 135, 36,-32766,-32766,-32766,-32766, 675, + -32766,-32766,-32766, 80, 1145, 544, -551,-32766,-32766, 309, + -551,-32766,-32766,-32766, -293,-32766,-32766,-32766, 245,-32766, + -189,-32766,-32766,-32766,-32766,-32766,-32766,-32766,-32766,-32766, + 31, 433, 429,-32766,-32766, -502, -502, 701, 782,-32766, + 388, 391,-32766,-32766,-32766, 235, 126,-32766, -82, 142, + -502, 261, 136, 372, 705, 706, 707, 708, 247, -188, + 397, 292, -502,-32766, -508,-32766,-32766, 709, 710, 711, + 712, 713, 714, 715, 716, 717, 718, 719, 739, 553, + 740, 741, 742, 743, 731, 732, 373, 374, 734, 735, + 720, 721, 722, 724, 725, 726, 333, 765, 766, 767, + 768, 769, 727, 728, 554, 555, 760, 751, 749, 750, + 746, 747, 294, -82, 556, 557, 745, 558, 559, 560, + 561, 562, 563, 310, 81, 82, 83, -548, 748, 564, + 565, -548, 137, 723, 693, 694, 695, 696, 697,-32766, + 698, 699, 700, 736, 737, 33, 307, 84, 85, 86, + 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, + 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, + 322, 263,-32766,-32766,-32766, 104, 105, 106, 346, 263, + 952, 951, 950, 107, 350, 438, 439, 701,-32766,-32766, + -32766, 107, -253,-32766, 355,-32766,-32766,-32766,-32766,-32766, + -32766, 702, 703, 704, 705, 706, 707, 708, 452,-32766, + 770,-32766,-32766,-32766,-32766,-32766, 357, 709, 710, 711, + 712, 713, 714, 715, 716, 717, 718, 719, 739, 762, + 740, 741, 742, 743, 731, 732, 733, 761, 734, 735, + 720, 721, 722, 724, 725, 726, 764, 765, 766, 767, + 768, 769, 727, 728, 729, 730, 760, 751, 749, 750, + 746, 747, 619, 24, 738, 744, 745, 752, 753, 755, + 754, 756, 757, 524,-32766,-32766,-32766, 574, 748, 759, + 758, 48, 49, 50, 483, 51, 52, 147, 397, 580, + 408, 53, 54, 409, 55,-32766, 975,-32766,-32766,-32766, + -32766,-32766,-32766,-32767,-32767,-32767,-32767,-32767, 865,-32767, + -32767,-32767,-32767, 99, 100, 101, 102, 103, 1257, 410, + 1172, 1258, 411, 1145, 865, 271, 634, 635, 56, 57, + 148, 808, 1184, 809, 58, 453, 59, 240, 241, 60, + 61, 62, 63, 64, 65, 66, 67, 787, 26, 262, + 68, 412, 484, 121, 667,-32766, 1178, 1179, 485, 1143, + 781, 1147, 1146, 1148, 1176, 40, 23, 486, 1002, 487, + 150, 488, 234, 489, 962, 963, 490, 491, 780, 423, + 424, 42, 43, 413, 417, 415, 865, 44, 492, 151, + 855, 920, 248, 345, 321, 1152, 1147, 1146, 1148, 122, + 781, 493, 494, 495, 152, -330, 855, -330, 127, -505, + 960, 154, 496, 497, 35, 1166, 1167, 1168, 1169, 1163, + 1164, 280, 146, 377, 26, -14, 128, 1170, 1165, 962, + 963, 1147, 1146, 1148, 281, 141, 781, -501, 155, 69, + 1176, 305, 306, 309, 34, 108, 109, 110, 111, 112, + 113, 114, 115, 116, 117, 118, 119, 120, 156, -149, + -149, -149, 478, 867, 18, 662, 1152, 1152, 855, 440, + 441, -505, -505, 157, -149, 781, -149, 138, -149, 867, + -149, 662, 808, 309, 809, 242, 1060, 1062, 496, 497, + 414, 1166, 1167, 1168, 1169, 1163, 1164, -500, -505, -501, + -501, -107, -107, 1170, 1165, -503, 1228, 865, 611, 612, + 841, -107, -107, -107, -501, 71, 921, -84, 306, 309, + -107,-32766, -76, 1001, -49, 686, -501, 1145, -507, -73, + -71, 774, -70, -69,-32766,-32766,-32766, 668,-32766, -68, + -32766, 867,-32766, 662, -149,-32766, 781, 781, -67, 281, + -32766,-32766,-32766, -66, 73, -65,-32766,-32766, 309, -500, + -500, 129,-32766, 388, -64, -45,-32766, -503, -503, -16, + -32766, 145, 1145, 264, -500, 676, 865, 679, 864,-32766, + -32766,-32766, -503,-32766, 772,-32766, -500,-32766, 144, 855, + -32766, 272, -107, 273, -503,-32766,-32766,-32766, 879, 72, + 244,-32766,-32766,-32766, 275, 776, 669,-32766, 388, 1145, + 664, 865, -500, 274, 276,-32766,-32766,-32766,-32766, 315, + -32766, 281,-32766, 263,-32766, 73, 73,-32766, 107, 309, + 309, 143,-32766,-32766,-32766, 642,-32766, 246,-32766,-32766, + 532, 671, 1145, 772,-32766, 388, -4, 865, 1259,-32766, + -32766,-32766,-32766,-32766, 781,-32766,-32766,-32766, 855, 1030, + -32766, 865, 867, 139, 662,-32766,-32766,-32766, 655, 309, + 865,-32766,-32766,-32766, -500, -500, 526,-32766, 388, 1145, + 101, 102, 103, 620, 637,-32766,-32766,-32766,-32766, -500, + -32766, 960,-32766, 855,-32766, 20, 865,-32766,-32766, 625, + 677, -500,-32766,-32766,-32766, 435,-32766, 463,-32766,-32766, + 962, 963, 1145, 626,-32766, 388, 638, 962, 963,-32766, + -32766,-32766,-32766,-32766, 609,-32766, 289,-32766, 46, 855, + -32766, 906, 407, 662,-32766,-32766,-32766,-32766, 287, 1016, + 1183,-32766,-32766, 855, 286, 293, 781,-32766, 388, 1247, + 890, 414, 855, 402, 891,-32766, 881, 538, 279, -231, + -231, -231, -107, -107, 1000, 414, 867, 26, 662, 1185, + 578, 800, -107, -107, -107, -466, -107, -107, 855, 781, + 47, -456, 7, 1176, 22, 841, -107, -107, -107, 348, + 282, 283, 780, 9, -230, -230, -230, 281, 1173, -536, + 414, 38, 867, 39, 662, -4, 683, 684, 846, 32, + 243, -107, -107, 930, 907, 680, 867, 123, 662, -231, + 841, -107, -107, -107, 914, 867, 904, 662, 915, 844, + 902, 1005, 497, 1008, 1166, 1167, 1168, 1169, 1163, 1164, + 1009, 1006, 284, 285, 1007, 1013, 1170, 1165, 792, 1198, + 1216, 867, 30, 662, -230, 304, 1250, 349, 71, 614, + 842, 306, 309, 347, 663, 666, 670, 672, -107, 125, + -107, 673, 674, 678, 665, 288, 1254, 1256, -107, -107, + -107, -107, -107, -107, -107, 803, 802, 811, 888, 922, + 810, 1255, 887, 886, 1131, 874, 882, 872, 912, 913, + 1253, 1210, 1199, 1217, 1223, 1226, 0, -534, -508, -507, + -506, 1, 27, 28, 37, 41, 45, 70, 74, 75, + 76, 77, -307, -256, 78, 79, 140, 149, 153, 239, + 311, 334, 335, 336, 337, 338, 339, 340, 341, 342, + 343, 344, 403, 404, 0, -254, -253, 12, 13, 14, + 15, 17, 376, 454, 455, 462, 465, 466, 467, 468, + 472, 473, 474, 481, 649, 1156, 1099, 1174, 977, 1135, + -258, -99, 11, 16, 25, 278, 375, 571, 575, 601, + 654, 1103, 1151, 1100, 1229, 0, -470, 1116, 0, 1177, + 0, 309 ); protected $actionCheck = array( - 2, 3, 4, 5, 6, 78, 8, 9, 10, 11, - 12, 0, 15, 16, 17, 18, 19, 20, 21, 22, - 23, 24, 25, 26, 27, 28, 42, 43, 44, 45, - 46, 47, 48, 49, 50, 8, 9, 10, 78, 79, - 7, 114, 115, 116, 117, 118, 119, 114, 115, 116, - 117, 118, 119, 55, 57, 58, 29, 7, 31, 32, - 33, 34, 35, 36, 8, 9, 10, 69, 70, 71, - 72, 73, 74, 75, 114, 1, 78, 8, 9, 10, - 1, 7, 13, 85, 86, 87, 88, 89, 90, 91, + 2, 3, 4, 5, 6, 7, 0, 9, 10, 11, + 12, 13, 1, 116, 117, 73, 1, 9, 10, 11, + 1, 79, 79, 126, 127, 128, 1, 8, 86, 87, + 88, 8, 90, 8, 92, 37, 94, 8, 30, 97, + 32, 33, 34, 101, 102, 103, 104, 9, 10, 11, + 108, 109, 14, 1, 56, 79, 114, 115, 115, 116, + 117, 118, 119, 120, 122, 105, 106, 1, 70, 71, + 72, 73, 74, 75, 76, 115, 8, 79, 115, 116, + 117, 118, 119, 120, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, 119, 120, 121, - 122, 123, 124, 125, 126, 127, 128, 129, 30, 131, - 132, 133, 134, 135, 136, 137, 138, 139, 2, 3, - 4, 5, 6, 145, 146, 147, 7, 11, 12, 36, - 14, 8, 9, 10, 48, 49, 50, 68, 8, 9, - 10, 68, 29, 7, 1, 8, 9, 10, 1, 80, - 8, 9, 29, 84, 31, 32, 33, 34, 35, 29, - 7, 31, 32, 33, 48, 49, 29, 154, 31, 32, - 54, 78, 56, 57, 58, 59, 60, 61, 62, 63, - 64, 65, 66, 114, 68, 69, 70, 71, 8, 9, - 10, 13, 76, 77, 78, 1, 80, 7, 1, 49, - 84, 132, 1, 130, 1, 80, 7, 114, 154, 29, - 156, 31, 32, 33, 34, 1, 7, 144, 7, 103, - 104, 1, 153, 80, 151, 78, 153, 158, 78, 151, - 114, 81, 7, 51, 52, 53, 7, 55, 122, 123, - 30, 8, 149, 29, 36, 132, 133, 131, 132, 67, - 134, 135, 136, 137, 138, 139, 140, 114, 68, 68, - 7, 145, 146, 147, 148, 13, 78, 154, 125, 153, - 36, 155, 1, 157, 158, 72, 73, 74, 75, 0, - 1, 80, 7, 158, 1, 82, 78, 7, 85, 86, - 87, 88, 89, 90, 91, 92, 93, 94, 151, 96, - 103, 158, 105, 100, 101, 102, 103, 154, 111, 106, - 107, 68, 78, 110, 29, 114, 113, 120, 115, 116, - 130, 130, 114, 7, 121, 68, 68, 124, 125, 126, - 127, 68, 154, 145, 144, 144, 148, 8, 9, 10, - 152, 151, 151, 30, 154, 151, 132, 133, 114, 152, - 7, 72, 1, 150, 151, 152, 29, 149, 29, 158, - 150, 82, 154, 80, 85, 86, 87, 36, 89, 7, - 91, 151, 93, 130, 1, 96, 78, 36, 36, 100, - 101, 102, 103, 149, 105, 106, 107, 130, 130, 110, - 111, 78, 113, 130, 115, 116, 103, 7, 105, 68, - 121, 144, 7, 124, 125, 126, 127, 144, 151, 151, - 68, 80, 7, 7, 151, 84, 153, 132, 133, 78, - 7, 150, 80, 72, 145, 1, 84, 114, 30, 150, - 151, 152, 83, 82, 151, 7, 85, 86, 87, 154, - 89, 158, 91, 145, 93, 114, 148, 96, 97, 98, - 99, 100, 101, 102, 103, 114, 114, 106, 107, 132, - 133, 110, 131, 132, 113, 36, 115, 116, 95, 103, - 154, 105, 121, 131, 132, 124, 125, 126, 127, 80, - 148, 13, 83, 151, 153, 103, 36, 105, 13, 158, - 141, 13, 103, 78, 105, 153, 72, 154, 73, 74, - 158, 150, 151, 152, 73, 74, 82, 78, 15, 85, - 86, 87, 15, 89, 148, 91, 154, 93, 98, 99, - 96, 97, 98, 99, 100, 101, 102, 103, 78, 114, - 106, 107, 15, 1, 110, 103, 104, 113, 15, 115, - 116, 142, 143, 114, 154, 121, 108, 109, 124, 125, - 126, 127, 15, 132, 133, 15, 8, 9, 10, 154, - 150, 151, 30, 30, 114, 15, 15, 36, 30, 30, - 34, 30, 30, 55, 150, 151, 152, 29, 34, 31, - 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, - 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, - 52, 53, 34, 55, 72, 75, 1, 78, 80, 83, - 67, 87, 78, 68, 82, 67, 81, 85, 86, 87, - 68, 89, 95, 91, 78, 93, 111, 80, 96, 125, - 114, 112, 100, 101, 102, 30, 83, 88, 106, 107, - 128, 128, 110, 129, 90, 113, 125, 92, 141, 141, - 94, 148, 1, 121, 95, 95, 150, 148, 97, 97, - 149, 151, 157, -1, 144, -1, 144, -1, -1, 144, - -1, -1, -1, -1, -1, -1, -1, 72, -1, -1, - -1, 30, 150, 151, -1, -1, -1, 82, -1, -1, - 85, 86, 87, -1, 89, -1, 91, -1, 93, 1, - -1, 96, 144, -1, -1, 100, 101, 102, 151, -1, - -1, 106, 107, 148, 148, 110, 152, 148, 113, 148, - 148, 148, 152, 72, 150, 150, 121, 150, 30, 150, - 150, 150, 150, 82, 150, 150, 85, 86, 87, 150, - 89, 150, 91, 150, 93, 1, 150, 96, 150, 150, - 150, 100, 101, 102, 150, 150, 151, 106, 107, 150, - 150, 110, 151, 151, 113, 151, 151, 151, 151, 151, - 72, 151, 121, 151, 30, 151, 153, 152, 152, 152, - 82, 152, 152, 85, 86, 87, 152, 89, 152, 91, - 152, 93, 1, 152, 96, 152, 152, 152, 100, 101, - 102, 150, 151, 153, 106, 107, 152, 152, 110, 152, - 152, 113, 152, 152, 152, 152, 72, 152, 152, 121, - 152, 152, 155, 153, 153, 153, 82, 153, 153, 85, - 86, 87, 153, 89, 153, 91, 153, 93, 153, 153, - 96, 153, 153, 153, 100, 101, 102, 153, 150, 151, - 106, 107, 153, 153, 110, 153, 153, 113, 153, 153, - 153, 153, 153, 72, 153, 121, 153, 153, 153, 153, - -1, 154, 154, 82, 154, 154, 85, 86, 87, 154, - 89, 154, 91, 154, 93, 154, 154, 96, 154, 154, - 154, 100, 101, 102, 150, 151, 154, 106, 107, 154, - 154, 110, 154, 154, 113, 8, 9, 10, 154, 154, - 154, 154, 121, 154, 154, 154, 154, 154, 154, 154, - 154, 154, 154, 154, -1, 155, 29, 156, 31, 32, - 33, 34, 35, 36, 37, 38, 39, 40, 41, 156, - 156, 150, 151, 156, 156, 156 + 122, 123, 124, 125, 126, 127, 128, 129, 130, 153, + 8, 133, 134, 135, 136, 137, 138, 139, 140, 141, + 157, 1, 8, 69, 161, 147, 148, 149, 8, 151, + 9, 10, 11, 2, 3, 4, 5, 6, 7, 161, + 9, 10, 11, 12, 13, 9, 10, 11, 73, 158, + 9, 10, 11, 158, 79, 80, 157, 9, 10, 164, + 161, 86, 87, 88, 161, 90, 30, 92, 37, 94, + 161, 30, 97, 32, 33, 34, 35, 102, 103, 104, + 8, 105, 106, 108, 109, 131, 132, 56, 156, 114, + 115, 115, 9, 10, 11, 14, 8, 122, 31, 8, + 146, 70, 71, 72, 73, 74, 75, 76, 8, 161, + 79, 8, 158, 30, 160, 32, 33, 86, 87, 88, + 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, + 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, + 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, + 119, 120, 121, 122, 123, 124, 125, 126, 127, 128, + 129, 130, 8, 96, 133, 134, 135, 136, 137, 138, + 139, 140, 141, 69, 9, 10, 11, 157, 147, 148, + 149, 161, 151, 2, 3, 4, 5, 6, 7, 9, + 9, 10, 11, 12, 13, 30, 8, 32, 33, 34, + 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, + 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, + 8, 56, 9, 10, 11, 52, 53, 54, 8, 56, + 118, 119, 120, 68, 8, 131, 132, 56, 9, 10, + 11, 68, 161, 30, 8, 32, 33, 34, 35, 36, + 37, 70, 71, 72, 73, 74, 75, 76, 31, 30, + 79, 32, 33, 34, 35, 36, 8, 86, 87, 88, + 89, 90, 91, 92, 93, 94, 95, 96, 97, 98, + 99, 100, 101, 102, 103, 104, 105, 106, 107, 108, + 109, 110, 111, 112, 113, 114, 115, 116, 117, 118, + 119, 120, 121, 122, 123, 124, 125, 126, 127, 128, + 129, 130, 74, 75, 133, 134, 135, 136, 137, 138, + 139, 140, 141, 84, 9, 10, 11, 1, 147, 148, + 149, 2, 3, 4, 5, 6, 7, 14, 79, 50, + 8, 12, 13, 8, 15, 30, 1, 32, 33, 34, + 35, 36, 37, 38, 39, 40, 41, 42, 1, 43, + 44, 45, 46, 47, 48, 49, 50, 51, 79, 8, + 1, 82, 8, 79, 1, 30, 74, 75, 49, 50, + 14, 105, 143, 107, 55, 158, 57, 58, 59, 60, + 61, 62, 63, 64, 65, 66, 67, 8, 69, 70, + 71, 72, 73, 16, 31, 115, 77, 78, 79, 115, + 81, 152, 153, 154, 85, 86, 87, 88, 159, 90, + 14, 92, 96, 94, 134, 135, 97, 98, 152, 105, + 106, 102, 103, 104, 105, 106, 1, 108, 109, 14, + 83, 31, 37, 114, 115, 1, 152, 153, 154, 16, + 81, 122, 123, 124, 14, 105, 83, 107, 16, 69, + 115, 14, 133, 134, 14, 136, 137, 138, 139, 140, + 141, 142, 100, 101, 69, 31, 16, 148, 149, 134, + 135, 152, 153, 154, 155, 16, 81, 69, 16, 160, + 85, 162, 163, 164, 16, 17, 18, 19, 20, 21, + 22, 23, 24, 25, 26, 27, 28, 29, 16, 74, + 75, 76, 105, 156, 107, 158, 1, 1, 83, 105, + 106, 131, 132, 16, 89, 81, 91, 158, 93, 156, + 95, 158, 105, 164, 107, 37, 58, 59, 133, 134, + 105, 136, 137, 138, 139, 140, 141, 69, 158, 131, + 132, 116, 117, 148, 149, 69, 1, 1, 110, 111, + 125, 126, 127, 128, 146, 160, 156, 31, 163, 164, + 126, 73, 31, 156, 31, 158, 158, 79, 160, 31, + 31, 79, 31, 31, 86, 87, 88, 31, 90, 31, + 92, 156, 94, 158, 159, 97, 81, 81, 31, 155, + 102, 103, 104, 31, 160, 31, 108, 109, 164, 131, + 132, 31, 114, 115, 31, 31, 73, 131, 132, 31, + 122, 31, 79, 31, 146, 31, 1, 31, 31, 86, + 87, 88, 146, 90, 79, 92, 158, 94, 31, 83, + 97, 35, 126, 35, 158, 102, 103, 104, 37, 151, + 37, 108, 109, 73, 35, 153, 31, 114, 115, 79, + 158, 1, 69, 30, 35, 122, 86, 87, 88, 35, + 90, 155, 92, 56, 94, 160, 160, 97, 68, 164, + 164, 69, 102, 103, 104, 76, 73, 37, 108, 109, + 88, 31, 79, 79, 114, 115, 0, 1, 82, 86, + 87, 88, 122, 90, 81, 92, 84, 94, 83, 81, + 97, 1, 156, 158, 158, 102, 103, 104, 91, 164, + 1, 108, 109, 73, 131, 132, 84, 114, 115, 79, + 49, 50, 51, 89, 93, 122, 86, 87, 88, 146, + 90, 115, 92, 83, 94, 96, 1, 97, 115, 95, + 31, 158, 102, 103, 104, 96, 73, 96, 108, 109, + 134, 135, 79, 99, 114, 115, 99, 134, 135, 86, + 87, 88, 122, 90, 112, 92, 113, 94, 69, 83, + 97, 156, 126, 158, 115, 102, 103, 104, 130, 121, + 143, 108, 109, 83, 129, 129, 81, 114, 115, 84, + 126, 105, 83, 107, 126, 122, 151, 150, 112, 99, + 100, 101, 116, 117, 1, 105, 156, 69, 158, 143, + 150, 125, 126, 127, 128, 146, 116, 117, 83, 81, + 69, 146, 146, 85, 146, 125, 126, 127, 128, 146, + 131, 132, 152, 147, 99, 100, 101, 155, 157, 160, + 105, 156, 156, 156, 158, 159, 156, 156, 156, 144, + 145, 116, 117, 156, 156, 159, 156, 158, 158, 159, + 125, 126, 127, 128, 156, 156, 156, 158, 156, 156, + 156, 156, 134, 156, 136, 137, 138, 139, 140, 141, + 156, 156, 131, 132, 156, 156, 148, 149, 157, 157, + 157, 156, 158, 158, 159, 158, 157, 146, 160, 157, + 159, 163, 164, 158, 158, 158, 158, 158, 105, 158, + 107, 158, 158, 158, 158, 112, 159, 159, 115, 116, + 117, 118, 119, 120, 121, 159, 159, 159, 159, 159, + 159, 159, 159, 159, 159, 159, 159, 159, 159, 159, + 159, 159, 159, 159, 159, 159, -1, 160, 160, 160, + 160, 160, 160, 160, 160, 160, 160, 160, 160, 160, + 160, 160, 159, 161, 160, 160, 160, 160, 160, 160, + 160, 160, 160, 160, 160, 160, 160, 160, 160, 160, + 160, 160, 160, 160, -1, 161, 161, 161, 161, 161, + 161, 161, 161, 161, 161, 161, 161, 161, 161, 161, + 161, 161, 161, 161, 161, 161, 161, 161, 161, 161, + 161, 161, 161, 161, 161, 161, 161, 161, 161, 161, + 161, 161, 161, 161, 161, -1, 162, 162, -1, 163, + -1, 164 ); protected $actionBase = array( - 0, 223, 299, 371, 444, 303, 208, 629, -2, -2, - -73, -2, -2, 625, 718, 718, 764, 718, 552, 671, - 811, 811, 811, 228, 113, 113, 113, 254, 361, -40, - 361, 333, 449, 470, 435, 435, 435, 435, 435, 435, - 435, 435, 435, 435, 435, 435, 435, 435, 435, 435, - 435, 435, 435, 435, 435, 435, 435, 435, 435, 435, - 435, 435, 435, 435, 435, 435, 435, 435, 435, 435, - 435, 435, 435, 435, 435, 435, 435, 435, 435, 435, - 435, 435, 435, 435, 435, 435, 435, 435, 435, 435, - 435, 435, 435, 435, 435, 435, 435, 435, 435, 435, - 435, 435, 435, 435, 435, 435, 435, 435, 435, 435, - 435, 435, 435, 435, 435, 435, 435, 435, 435, 435, - 435, 435, 435, 435, 435, 435, 435, 435, 435, 435, - 435, 435, 435, 435, 435, 435, 435, 435, 435, 435, - 291, 291, 230, 393, 495, 783, 788, 785, 781, 780, - 784, 789, 498, 682, 683, 562, 685, 686, 688, 689, - 786, 809, 782, 787, 568, 568, 568, 568, 568, 568, - 568, 568, 568, 568, 568, 568, 568, 568, 568, 568, - 568, 253, 69, 162, 56, 56, 56, 56, 56, 56, - 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, - 56, 56, 56, 56, 56, 56, 349, 349, 349, 157, - 210, 150, 200, 211, 143, 27, 917, 917, 917, 917, - 917, -16, -16, -16, -16, 351, 351, 362, 217, 89, - 89, 89, 89, 89, 89, 89, 89, 89, 89, 89, - 89, 89, 163, 313, 106, 106, 133, 133, 133, 133, - 133, 133, 305, 221, 234, 347, 369, 528, 525, 167, - 167, 441, 441, 441, 93, 283, 202, 202, 202, 386, - 573, 536, 536, 536, 536, 419, 419, 536, 536, 170, - 214, 74, 211, 211, 277, 211, 211, 211, 409, 409, - 409, 452, 318, 352, 546, 318, 630, 644, 581, 680, - 582, 681, 278, 592, 145, 593, 145, 145, 145, 458, - 445, 451, 779, 291, 540, 291, 291, 291, 291, 726, - 291, 291, 291, 291, 291, 291, 98, 291, 79, 430, - 230, 240, 240, 588, 240, 452, 538, 263, 637, 410, - 425, 538, 538, 538, 638, 640, 336, 363, 198, 642, - 382, 402, 173, 33, 549, 549, 554, 554, 567, 551, - 549, 549, 549, 549, 549, 694, 694, 554, 548, 554, - 567, 703, 554, 551, 551, 554, 554, 549, 554, 694, - 551, 156, 415, 249, 273, 551, 551, 426, 532, 549, - 533, 533, 433, 554, 219, 554, 139, 534, 694, 694, - 534, 229, 551, 231, 595, 597, 535, 531, 553, 245, - 553, 553, 300, 535, 553, 551, 553, 448, 50, 548, - 295, 553, 11, 705, 706, 418, 708, 701, 709, 735, - 710, 530, 524, 541, 723, 725, 714, 699, 695, 561, - 591, 513, 517, 542, 565, 692, 589, 563, 563, 563, - 565, 690, 563, 563, 563, 563, 563, 563, 563, 563, - 791, 578, 544, 727, 537, 523, 580, 543, 577, 527, - 591, 591, 590, 687, 790, 566, 726, 769, 719, 526, - 557, 751, 728, 584, 529, 585, 729, 731, 752, 774, - 631, 513, 775, 645, 572, 646, 591, 647, 563, 670, - 643, 803, 804, 691, 807, 741, 754, 556, 564, 755, - 586, 649, 555, 808, 650, 776, 632, 634, 594, 745, - 737, 756, 654, 762, 765, 656, 599, 569, 738, 576, - 736, 272, 734, 635, 658, 661, 663, 664, 665, 720, - 600, 747, 575, 749, 740, 601, 602, 560, 674, 488, - 604, 570, 571, 605, 722, 558, 550, 609, 611, 777, - 675, 733, 613, 677, 768, 547, 589, 545, 539, 579, - 574, 636, 766, 559, 616, 618, 619, 620, 678, 624, + 0, -2, 151, 555, 816, 830, 865, 489, 379, 622, + 858, 676, 780, 780, 839, 780, 493, 745, 301, 301, + -57, 301, 301, 477, 477, 477, 618, 618, 618, 618, + -58, -58, 95, 700, 733, 770, 663, 803, 803, 803, + 803, 803, 803, 803, 803, 803, 803, 803, 803, 803, + 803, 803, 803, 803, 803, 803, 803, 803, 803, 803, + 803, 803, 803, 803, 803, 803, 803, 803, 803, 803, + 803, 803, 803, 803, 803, 803, 803, 803, 803, 803, + 803, 803, 803, 803, 803, 803, 803, 803, 803, 803, + 803, 803, 803, 803, 803, 803, 803, 803, 803, 803, + 803, 803, 803, 803, 803, 803, 803, 803, 803, 803, + 803, 803, 803, 803, 803, 803, 803, 803, 803, 803, + 803, 803, 803, 803, 803, 803, 803, 803, 803, 803, + 803, 803, 803, 803, 803, 803, 803, 803, 803, 803, + 803, 803, 803, 803, 803, 803, 803, 803, 803, 803, + 803, 803, 803, 803, 803, 803, 803, 803, 52, 530, + 446, 570, 984, 990, 986, 991, 982, 981, 985, 987, + 992, 911, 912, 727, 913, 914, 915, 916, 988, 872, + 983, 989, 285, 285, 285, 285, 285, 285, 285, 285, + 285, 285, 285, 285, 285, 285, 285, 285, 285, 285, + 285, 285, 285, 300, 38, 168, 141, 141, 141, 141, + 141, 141, 141, 141, 141, 141, 141, 141, 141, 141, + 141, 141, 141, 141, 141, 141, 141, 141, 141, 141, + 156, 156, 156, 203, 525, 525, 8, 598, 161, 868, + 868, 868, 868, 868, 868, 868, 868, 868, 868, 349, + 333, 435, 435, 435, 435, 435, 436, 436, 436, 436, + 933, 564, 636, 635, 465, 470, 801, 801, 753, 753, + 788, 746, 746, 746, 410, 410, 410, 74, 538, 396, + 359, 414, 675, 675, 675, 675, 414, 414, 414, 414, + 796, 996, 414, 414, 414, -103, 606, 713, 713, 881, + 293, 293, 293, 713, 547, 762, 835, 547, 835, 15, + 409, 789, -40, 96, -17, 789, 510, 829, 140, 19, + 810, 444, 810, 742, 859, 886, 993, 232, 784, 909, + 787, 910, 224, 661, 979, 979, 979, 979, 979, 979, + 979, 979, 979, 979, 979, 997, 980, -24, 997, 997, + 997, 568, -24, 358, 422, -24, 754, 980, 52, 805, + 52, 52, 52, 52, 941, 52, 52, 52, 52, 52, + 52, 946, 708, 704, 668, 347, 52, 530, 11, 11, + 537, 66, 11, 11, 11, 11, 52, 52, 444, 737, + 777, 534, 790, 68, 737, 737, 737, 187, 23, 201, + 29, 527, 734, 734, 731, 748, 921, 921, 734, 743, + 734, 748, 926, 734, 731, 731, 921, 731, 812, 208, + 452, 332, 346, 731, 731, 455, 921, 223, 731, 731, + 734, 734, 734, 731, 481, 734, 220, 211, 734, 734, + 731, 731, 785, 786, 122, 921, 921, 921, 786, 340, + 778, 778, 820, 821, 782, 712, 308, 274, 509, 192, + 731, 712, 712, 734, 356, 782, 712, 782, 712, 775, + 712, 712, 712, 782, 712, 743, 378, 712, 731, 484, + 134, 712, 6, 927, 928, 656, 929, 924, 930, 952, + 931, 934, 876, 939, 925, 935, 923, 922, 717, 507, + 553, 806, 799, 920, 730, 730, 730, 918, 730, 730, + 730, 730, 730, 730, 730, 730, 507, 811, 813, 776, + 722, 942, 562, 580, 767, 871, 994, 995, 794, 798, + 941, 974, 936, 815, 589, 960, 943, 826, 867, 944, + 945, 961, 975, 976, 887, 732, 888, 896, 861, 947, + 877, 730, 927, 934, 925, 935, 923, 922, 703, 694, + 687, 692, 678, 672, 669, 671, 710, 917, 809, 862, + 946, 919, 507, 863, 956, 864, 962, 963, 875, 779, + 736, 869, 897, 948, 949, 950, 878, 977, 817, 957, + 932, 964, 781, 898, 965, 966, 967, 968, 899, 879, + 883, 822, 764, 954, 774, 900, 443, 739, 749, 953, + 486, 940, 884, 901, 902, 969, 970, 971, 903, 937, + 827, 958, 761, 959, 955, 828, 838, 526, 726, 728, + 545, 560, 904, 905, 938, 714, 729, 840, 842, 978, + 906, 567, 843, 592, 907, 973, 612, 627, 747, 885, + 808, 783, 769, 951, 716, 844, 908, 845, 847, 854, + 972, 855, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 449, + 449, 449, 449, 449, 449, 301, 301, 301, 301, 449, + 449, 449, 449, 449, 449, 449, 0, 0, 301, 0, + 0, 449, 449, 449, 449, 449, 449, 449, 449, 449, + 449, 449, 449, 449, 449, 449, 449, 449, 449, 449, + 449, 449, 449, 449, 449, 449, 449, 449, 449, 449, + 449, 449, 449, 449, 449, 449, 449, 449, 449, 449, + 449, 449, 449, 449, 449, 449, 449, 449, 449, 449, + 449, 449, 449, 449, 449, 449, 449, 449, 449, 449, + 449, 449, 449, 449, 449, 449, 449, 449, 449, 449, + 449, 449, 449, 449, 449, 449, 449, 449, 449, 449, + 449, 449, 449, 449, 449, 449, 449, 449, 449, 449, + 449, 449, 449, 449, 449, 449, 449, 449, 449, 449, + 449, 449, 449, 449, 449, 449, 449, 449, 449, 449, + 449, 449, 449, 449, 449, 449, 449, 449, 449, 449, + 449, 449, 449, 449, 449, 449, 449, 449, 449, 449, + 449, 449, 449, 449, 449, 449, 285, 285, 285, 285, + 285, 285, 285, 285, 285, 285, 285, 285, 285, 285, + 285, 285, 285, 285, 285, 285, 285, 285, 285, 285, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 136, 136, 136, - 136, -2, -2, -2, 0, 0, -2, 0, 0, 136, - 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, - 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, - 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, - 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, - 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, - 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, - 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, - 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, - 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, - 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, - 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, - 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, - 136, 136, 136, 136, 136, 136, 568, 568, 568, 568, - 568, 568, 568, 568, 568, 568, 568, 568, 568, 568, - 568, 568, 568, 568, 568, 568, 568, 568, 568, 568, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 568, 568, 568, - 568, 568, 568, 568, 568, 568, 568, 568, 568, 568, - 568, 568, 568, 568, 568, 568, 568, 568, 568, 568, - 568, 568, 568, 568, 568, 568, -3, 568, 568, -3, - 568, 568, 568, 568, 568, 568, 568, 202, 202, 202, - 202, 318, 318, 318, -67, 318, 318, 318, 318, 318, - 318, 318, 318, 318, 318, 318, 318, 318, 318, -67, - 202, 202, 318, 318, 318, 318, 318, 318, 318, 318, - 318, 318, 419, 419, 419, 145, 145, 318, 318, 318, - 0, 0, 0, 0, 0, 549, 419, 318, 318, 318, - 318, 0, 0, 318, 318, 548, 145, 0, 0, 0, - 0, 0, 0, 0, 549, 549, 549, 548, 0, 549, - 419, 0, 240, 291, 440, 440, 440, 440, 0, 549, - 0, 549, 0, 0, 0, 0, 0, 0, 551, 0, - 694, 0, 0, 0, 0, 554, 0, 0, 0, 0, - 0, 0, 0, 0, 548, 0, 0, 0, 0, 548, - 0, 0, 563, 0, 566, 0, 0, 563, 563, 563, - 566, 566, 0, 0, 0, 566 + 0, 285, 285, 285, 285, 285, 285, 285, 285, 285, + 285, 285, 285, 285, 285, 285, 285, 285, 285, 285, + 285, 285, 285, 285, 285, 285, 285, 285, 285, 285, + 285, 285, 414, 414, 285, 0, 285, 414, 414, 414, + 414, 414, 414, 414, 414, 414, 414, 285, 285, 285, + 285, 285, 285, 285, 293, 293, 293, 293, 812, 414, + 414, 414, 414, -37, 293, 293, 414, 414, -37, 414, + 414, 414, 414, 414, 414, 0, 0, -24, 835, 0, + 743, 743, 743, 743, 0, 0, 0, 0, 835, 835, + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 0, -24, 835, 0, -24, 0, 743, 743, 414, + 812, 812, 25, 414, 0, 0, 0, 0, -24, 743, + -24, 835, 11, 52, 25, 0, 492, 492, 492, 492, + 0, 444, 812, 812, 812, 812, 812, 812, 812, 812, + 812, 812, 812, 743, 812, 0, 743, 743, 743, 0, + 0, 0, 0, 0, 743, 731, 0, 921, 0, 0, + 0, 0, 734, 0, 0, 0, 0, 0, 0, 734, + 926, 731, 731, 0, 0, 0, 0, 0, 0, 743, + 0, 0, 0, 0, 0, 0, 0, 730, 779, 0, + 779, 0, 730, 730, 730 ); protected $actionDefault = array( - 3,32767,32767,32767,32767,32767,32767,32767,32767, 92, + 3,32767, 99,32767,32767,32767,32767,32767,32767,32767, + 32767,32767,32767,32767,32767,32767,32767,32767,32767, 97, + 32767,32767,32767,32767,32767,32767, 554, 554, 554, 554, + 235, 99,32767,32767,32767,32767, 430, 349, 349, 349, + 32767,32767, 498, 498, 498, 498, 498, 498,32767,32767, + 32767,32767,32767,32767, 430,32767,32767,32767,32767,32767, + 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, - 32767,32767,32767,32767, 513, 513, 513, 94, 502,32767, - 502,32767,32767,32767, 317, 317, 317,32767, 457, 457, - 457, 457, 457, 457, 457,32767,32767,32767,32767,32767, - 397,32767,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, + 32767,32767,32767,32767,32767,32767, 97,32767,32767,32767, + 35, 5, 6, 8, 9, 48, 15,32767,32767,32767, + 32767,32767, 99,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, + 32767, 547,32767,32767,32767,32767,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, - 32767, 92,32767,32767,32767,32767,32767,32767,32767,32767, + 32767,32767, 434, 413, 414, 416, 417, 348, 499, 553, + 292, 550, 347, 142, 304, 294, 223, 295, 239, 240, + 266, 344, 146, 378, 431, 380, 429, 433, 379, 354, + 359, 360, 361, 362, 363, 364, 365, 366, 367, 368, + 369, 370, 371, 352, 353, 432, 435, 436, 439, 440, + 410, 409, 408, 376,32767,32767, 377, 351, 381,32767, + 32767,32767,32767,32767,32767,32767,32767, 99,32767, 383, + 382, 399, 400, 397, 398, 401, 402, 403, 404, 405, + 32767,32767,32767,32767,32767, 327, 390, 391, 283, 283, + 329,32767,32767,32767,32767,32767,32767, 492, 407,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, - 32767,32767,32767,32767, 509,32767,32767,32767,32767,32767, + 32767,32767, 99,32767, 97,32767, 494, 373, 375, 462, + 385, 386, 384, 355,32767, 469,32767, 99, 471,32767, + 32767,32767, 108,32767,32767,32767, 493,32767, 500, 500, + 32767, 455, 97,32767,32767,32767,32767, 261,32767,32767, + 32767,32767, 561, 455, 107, 107, 107, 107, 107, 107, + 107, 107, 107, 107, 107,32767, 107,32767,32767,32767, + 97, 185,32767, 249, 251, 99, 515, 190,32767, 474, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, - 32767,32767,32767,32767, 380, 381, 383, 384, 316, 458, - 512, 262, 508, 315, 130, 273, 264, 211, 243, 313, - 134, 345, 398, 347, 396, 400, 346, 322, 326, 327, - 328, 329, 330, 331, 332, 333, 334, 335, 336, 337, - 338, 320, 321, 399, 401, 402, 377, 376, 375, 343, - 319, 344, 348, 319, 350, 349, 366, 367, 364, 365, - 368, 369, 370, 371, 372,32767,32767,32767,32767,32767, - 32767,32767,32767,32767,32767,32767,32767,32767,32767, 94, - 32767,32767,32767, 296, 357, 358, 253, 253, 253, 253, - 253, 253, 253,32767,32767, 253,32767,32767,32767,32767, - 32767,32767,32767,32767, 451, 374, 352, 353, 351,32767, - 429,32767,32767,32767,32767,32767, 431,32767, 92,32767, - 32767,32767, 340, 342, 423, 511, 323, 510,32767,32767, - 94, 417,32767,32767,32767,32767,32767,32767,32767,32767, - 32767,32767, 426,32767,32767, 92,32767,32767, 92, 174, - 230, 232, 179,32767, 434,32767,32767,32767,32767,32767, + 32767,32767, 467, 190, 190,32767,32767,32767,32767,32767, + 32767,32767,32767,32767,32767,32767,32767,32767, 455, 395, + 135,32767, 135, 500, 387, 388, 389, 457, 500, 500, + 500,32767,32767,32767, 190,32767, 472, 472, 97, 97, + 97, 97, 467,32767, 190, 190,32767, 190, 108, 96, + 96, 96, 96, 190, 190, 96, 100, 98, 190, 190, + 32767,32767,32767, 190, 96,32767, 98, 98,32767,32767, + 190, 190, 206, 204, 98,32767, 519, 520, 204, 98, + 208, 208, 228, 228, 446, 285, 98, 96, 98, 98, + 190, 285, 285,32767, 98, 446, 285, 446, 285, 192, + 285, 285, 285, 446, 285,32767, 98, 285, 190, 96, + 96, 285,32767,32767,32767, 457,32767,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, - 32767,32767,32767,32767,32767, 417, 362, 520,32767, 459, - 32767, 354, 355, 356,32767,32767, 459, 459, 459,32767, - 459,32767, 459, 459,32767,32767,32767,32767,32767, 179, - 32767,32767,32767,32767, 94, 432, 432, 92, 92, 92, - 92, 427,32767, 179, 179,32767,32767,32767,32767,32767, - 179, 91, 91, 91, 91, 179, 179, 91, 194,32767, - 192, 192, 91,32767, 93,32767, 93, 196,32767, 473, - 196, 91, 179, 91, 216, 216, 408, 181, 255, 93, - 255, 255, 93, 408, 255, 179, 255, 91, 91,32767, - 91, 255,32767,32767,32767, 85,32767,32767,32767,32767, + 487,32767, 504, 517, 393, 394, 396, 502, 418, 419, + 420, 421, 422, 423, 424, 426, 549,32767, 461,32767, + 32767,32767,32767, 303, 559,32767, 559,32767,32767,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, - 419,32767, 439,32767, 452, 471,32767, 360, 361, 363, - 32767, 461, 385, 386, 387, 388, 389, 390, 391, 393, - 32767, 422,32767,32767,32767, 87, 121, 272,32767, 518, - 87, 420,32767, 518,32767,32767,32767,32767,32767,32767, - 32767,32767,32767,32767, 87, 87,32767,32767,32767,32767, - 32767, 498,32767, 519,32767, 459, 421,32767, 359, 435, - 478,32767,32767, 460,32767,32767,32767, 245, 247,32767, - 87,32767,32767,32767,32767,32767,32767,32767,32767,32767, - 439,32767,32767,32767,32767,32767,32767,32767, 459,32767, + 32767,32767,32767,32767, 560,32767, 500,32767,32767,32767, + 32767, 392, 7, 74, 41, 42, 50, 56, 478, 479, + 480, 481, 475, 476, 482, 477,32767, 483, 525,32767, + 32767, 501, 552,32767,32767,32767,32767,32767,32767, 135, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, - 32767,32767,32767,32767, 459,32767,32767, 242,32767,32767, - 32767, 312,32767,32767,32767,32767,32767,32767,32767,32767, - 32767,32767,32767,32767,32767, 85, 60,32767, 292,32767, + 487,32767, 133,32767,32767,32767,32767,32767,32767,32767, + 32767,32767,32767, 500,32767,32767,32767, 280, 282,32767, 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, - 136, 136, 3, 275, 3, 275, 136, 136, 136, 275, - 275, 136, 136, 136, 136, 136, 136, 136, 169, 224, - 227, 216, 216, 284, 136, 136 + 32767,32767,32767,32767, 500,32767,32767,32767, 268, 270, + 32767,32767,32767,32767,32767,32767,32767,32767,32767,32767, + 32767,32767,32767, 265,32767,32767, 343,32767,32767,32767, + 32767, 323,32767,32767,32767,32767,32767,32767,32767,32767, + 32767,32767, 148, 148, 3, 3, 306, 148, 148, 148, + 306, 148, 306, 306, 148, 148, 148, 148, 148, 148, + 180, 243, 246, 228, 228, 148, 315, 148 ); protected $goto = array( - 171, 144, 144, 144, 171, 152, 153, 152, 155, 187, - 172, 168, 168, 168, 168, 169, 169, 169, 169, 169, - 169, 169, 164, 165, 166, 167, 184, 182, 185, 447, - 448, 336, 449, 452, 453, 454, 455, 456, 457, 458, - 459, 931, 141, 145, 146, 147, 170, 148, 149, 143, - 150, 151, 154, 181, 183, 186, 206, 209, 211, 212, - 214, 215, 216, 217, 218, 219, 220, 221, 222, 223, - 224, 244, 245, 266, 267, 268, 341, 342, 343, 498, - 188, 189, 190, 191, 192, 193, 194, 195, 196, 197, - 198, 199, 200, 201, 202, 156, 203, 157, 173, 174, - 175, 207, 176, 158, 159, 160, 177, 161, 208, 142, - 204, 162, 178, 205, 179, 180, 163, 567, 210, 465, - 210, 520, 520, 1045, 769, 1045, 1045, 1045, 1045, 1045, - 1045, 1045, 1045, 1045, 1045, 1045, 1045, 1045, 470, 470, - 470, 576, 702, 470, 500, 317, 321, 477, 501, 502, - 504, 299, 764, 485, 765, 470, 450, 450, 450, 729, - 450, 450, 450, 450, 450, 450, 450, 450, 450, 450, - 450, 450, 450, 451, 451, 451, 703, 451, 451, 451, - 451, 451, 451, 451, 451, 451, 451, 451, 451, 451, - 1121, 1121, 276, 729, 1136, 729, 491, 258, 491, 518, - 541, 499, 899, 579, 470, 470, 467, 561, 897, 1121, - 484, 510, 470, 470, 470, 331, 332, 738, 483, 549, - 906, 334, 690, 600, 527, 529, 296, 471, 542, 560, - 563, 839, 570, 578, 835, 907, 733, 721, 871, 496, - 497, 875, 514, 547, 720, 720, 814, 701, 564, 811, - 730, 730, 730, 732, 719, 844, 492, 804, 828, 809, - 809, 807, 809, 599, 1112, 462, 837, 832, 515, 867, - 1020, 914, 737, 1100, 1016, 509, 521, 523, 524, 572, - 705, 724, 525, 467, 718, 315, 537, 538, 1009, 791, - 543, 1010, 852, 857, 858, 489, 710, 847, 760, 755, - 756, 770, 979, 711, 757, 708, 758, 759, 709, 862, - 763, 803, 329, 575, 358, 348, 544, 352, 1089, 339, - 339, 282, 283, 285, 495, 346, 286, 347, 287, 350, - 528, 353, 1090, 1091, 1019, 1021, 3, 4, 319, 463, - 303, 534, 722, 725, 297, 476, 325, 300, 301, 872, - 486, 487, 604, 1024, 1022, 1076, 548, 854, 854, 854, - 854, 854, 854, 854, 1024, 854, 854, 407, 1017, 1012, - 876, 734, 854, 854, 854, 816, 400, 1120, 1120, 517, - 11, 1086, 1024, 1024, 1024, 1024, 461, 916, 1024, 1024, - 1095, 1095, 1086, 842, 842, 1107, 1120, 461, 1097, 1097, - 416, 0, 0, 777, 0, 0, 778, 0, 0, 0, - 0, 0, 0, 0, 1123, 805, 805, 805, 805, 1082, - 0, 799, 806, 0, 0, 0, 0, 0, 0, 0, + 190, 190, 650, 1020, 979, 399, 624, 798, 1019, 658, + 393, 297, 298, 318, 546, 303, 398, 319, 400, 603, + 362, 366, 531, 569, 573, 161, 161, 161, 161, 187, + 187, 171, 173, 209, 191, 204, 187, 187, 187, 187, + 187, 188, 188, 188, 188, 188, 188, 182, 183, 184, + 185, 186, 206, 204, 207, 504, 505, 389, 506, 508, + 509, 510, 511, 512, 513, 514, 515, 1046, 162, 163, + 164, 189, 165, 166, 167, 160, 168, 169, 170, 172, + 203, 205, 208, 230, 233, 236, 238, 249, 250, 251, + 252, 253, 254, 255, 256, 257, 258, 259, 266, 267, + 300, 301, 302, 394, 395, 396, 551, 210, 211, 212, + 213, 214, 215, 216, 217, 218, 219, 220, 221, 222, + 223, 224, 174, 225, 175, 192, 193, 194, 231, 182, + 183, 184, 185, 186, 206, 1046, 195, 176, 177, 178, + 196, 192, 179, 232, 197, 159, 198, 226, 180, 199, + 227, 228, 181, 229, 200, 201, 202, 312, 312, 312, + 312, 801, 577, 591, 594, 595, 596, 597, 615, 616, + 617, 660, 799, 329, 530, 521, 590, 590, 568, 794, + 794, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, 1175, + 1175, 858, 779, 859, 806, 775, 854, 849, 850, 863, + 905, 807, 851, 804, 852, 853, 805, 295, 295, 295, + 295, 832, 857, 607, 607, 364, 521, 773, 530, 969, + 966, 967, 996, 997, 539, 540, 957, 964, 965, 371, + 549, 588, 621, 779, 570, 779, 1244, 1244, 1193, 1193, + 543, 584, 585, 1193, 1193, 1193, 1193, 1193, 1193, 1193, + 1193, 1193, 1193, 326, 1244, 1144, 1144, 1144, 961, 1140, + 1233, 469, 961, 961, 926, 961, 961, 961, 961, 961, + 961, 1225, 1225, 1225, 1225, 1144, 470, 360, 471, 21, + 1144, 1144, 1144, 1144, 477, 794, 1144, 1144, 1144, 332, + 437, 437, 567, 1012, 618, 661, 632, 633, 542, 332, + 332, 437, 623, 647, 647, 870, 653, 1010, 1094, 871, + 447, 1218, 1219, 814, 332, 332, 1141, 332, 826, 1260, + 5, 813, 6, 518, 518, 518, 789, 320, 1191, 1191, + 523, 791, 332, 1191, 1191, 1191, 1191, 1191, 1191, 1191, + 1191, 1191, 1191, 426, 405, 1142, 1201, 1202, 899, 899, + 899, 899, 370, 536, 426, 893, 900, 897, 380, 657, + 583, 507, 507, 308, 291, 1204, 507, 507, 507, 507, + 507, 507, 507, 507, 507, 507, 1243, 1243, 516, 516, + 516, 516, 1220, 1221, 819, 875, 1034, 572, 547, 582, + 643, 522, 534, 587, 1243, 816, 948, 522, 945, 534, + 685, 985, 363, 330, 331, 818, 828, 627, 924, 1246, + 392, 1137, 579, 812, 418, 418, 418, 448, 523, 550, + 442, 443, 989, 1029, 824, 1136, 910, 1251, 1252, 451, + 600, 537, 1215, 1215, 1215, 682, 602, 604, 0, 622, + 0, 0, 640, 644, 940, 648, 656, 936, 0, 0, + 797, 0, 822, 1227, 1227, 1227, 1227, 929, 903, 903, + 901, 903, 681, 0, 270, 519, 519, 0, 0, 520, + 938, 933, 0, 827, 815, 984, 0, 0, 988, 0, + 1211, 0, 0, 0, 1139, 0, 0, 908, 418, 418, + 418, 418, 418, 418, 418, 418, 418, 418, 418, 0, + 418, 0, 378, 379, 0, 0, 0, 630, 0, 631, + 898, 382, 383, 384, 0, 641, 987, 0, 385, 1213, + 1213, 987, 324, 1125, 884, 0, 0, 1126, 1129, 885, + 1130, 0, 1027, 831, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 874, 0, 1084, 1084, 874, 0, 0, - 482, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 0, 0, 0, 464, 480, 0, - 0, 0, 0, 0, 0, 0, 0, 0, 464, 0, - 480, 0, 0, 318, 0, 0, 468, 388, 0, 390, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, 0, 0, 728, 0, 1128 + 0, 0, 0, 0, 0, 0, 943, 943 ); protected $gotoCheck = array( - 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, - 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, - 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, - 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, - 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, - 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, - 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, - 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, - 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, - 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, - 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, - 33, 33, 33, 33, 33, 33, 33, 63, 56, 10, - 56, 86, 86, 86, 13, 86, 86, 86, 86, 86, - 86, 86, 86, 86, 86, 86, 86, 86, 10, 10, - 10, 8, 17, 10, 98, 49, 49, 49, 49, 49, - 49, 80, 55, 10, 55, 10, 136, 136, 136, 26, - 136, 136, 136, 136, 136, 136, 136, 136, 136, 136, - 136, 136, 136, 138, 138, 138, 18, 138, 138, 138, - 138, 138, 138, 138, 138, 138, 138, 138, 138, 138, - 149, 149, 135, 26, 12, 26, 85, 135, 85, 46, - 46, 7, 7, 7, 10, 10, 12, 7, 7, 149, - 10, 10, 10, 10, 10, 69, 69, 36, 39, 69, - 112, 69, 5, 39, 39, 39, 69, 10, 39, 39, - 39, 39, 39, 39, 39, 112, 14, 14, 14, 10, - 2, 14, 2, 12, 26, 26, 14, 16, 12, 40, - 26, 26, 26, 26, 26, 14, 137, 14, 16, 16, - 16, 16, 16, 16, 147, 16, 16, 16, 15, 95, - 93, 14, 14, 144, 14, 68, 68, 68, 68, 68, - 13, 15, 73, 12, 15, 52, 73, 73, 67, 67, - 54, 67, 91, 91, 91, 53, 13, 88, 13, 13, - 13, 13, 119, 13, 13, 13, 13, 13, 13, 90, - 13, 76, 76, 76, 89, 56, 56, 56, 140, 56, - 56, 56, 56, 56, 56, 56, 56, 56, 56, 56, - 56, 56, 142, 142, 12, 93, 37, 37, 65, 65, - 20, 24, 28, 30, 11, 65, 19, 80, 80, 97, - 65, 65, 82, 63, 93, 93, 23, 63, 63, 63, - 63, 63, 63, 63, 63, 63, 63, 65, 128, 125, - 100, 32, 63, 63, 63, 79, 71, 148, 148, 72, - 65, 98, 63, 63, 63, 63, 75, 115, 63, 63, - 8, 8, 98, 85, 85, 85, 148, 75, 98, 98, - 123, -1, -1, 63, -1, -1, 63, -1, -1, -1, - -1, -1, -1, -1, 148, 75, 75, 75, 75, 98, - -1, 75, 75, -1, -1, -1, -1, -1, -1, -1, + 41, 41, 71, 128, 111, 64, 64, 25, 128, 8, + 64, 64, 64, 64, 64, 64, 64, 64, 64, 64, + 57, 57, 57, 57, 57, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 22, 22, 22, + 22, 14, 77, 77, 77, 77, 77, 77, 77, 77, + 77, 77, 26, 88, 74, 74, 99, 99, 114, 21, + 21, 99, 99, 99, 99, 99, 99, 99, 99, 99, + 99, 63, 11, 63, 14, 6, 14, 14, 14, 14, + 48, 14, 14, 14, 14, 14, 14, 23, 23, 23, + 23, 44, 14, 107, 107, 74, 74, 5, 74, 107, + 107, 107, 14, 14, 74, 74, 105, 105, 105, 74, + 74, 54, 54, 11, 74, 11, 165, 165, 152, 152, + 154, 74, 74, 152, 152, 152, 152, 152, 152, 152, + 152, 152, 152, 161, 165, 71, 71, 71, 71, 19, + 163, 74, 71, 71, 94, 71, 71, 71, 71, 71, + 71, 8, 8, 8, 8, 71, 139, 60, 139, 74, + 71, 71, 71, 71, 139, 21, 71, 71, 71, 13, + 133, 133, 7, 7, 82, 7, 82, 82, 95, 13, + 13, 133, 62, 7, 7, 71, 7, 7, 135, 71, + 158, 158, 158, 34, 13, 13, 19, 13, 34, 13, + 45, 34, 45, 18, 18, 18, 19, 28, 153, 153, + 13, 17, 13, 153, 153, 153, 153, 153, 153, 153, + 153, 153, 153, 18, 103, 19, 19, 19, 18, 18, + 18, 18, 27, 8, 18, 18, 18, 84, 84, 84, + 8, 155, 155, 151, 151, 13, 155, 155, 155, 155, + 155, 155, 155, 155, 155, 155, 164, 164, 98, 98, + 98, 98, 160, 160, 38, 16, 16, 98, 2, 2, + 13, 8, 8, 16, 164, 36, 101, 8, 16, 8, + 90, 113, 8, 88, 88, 16, 40, 16, 16, 164, + 12, 144, 12, 16, 22, 22, 22, 141, 13, 8, + 8, 8, 116, 131, 8, 16, 87, 8, 8, 80, + 81, 47, 114, 114, 114, 47, 47, 47, -1, 47, + -1, -1, 47, 47, 47, 47, 47, 47, -1, -1, + 24, -1, 8, 114, 114, 114, 114, 24, 24, 24, + 24, 24, 24, -1, 23, 23, 23, -1, -1, 24, + 24, 24, -1, 15, 15, 15, -1, -1, 15, -1, + 114, -1, -1, -1, 13, -1, -1, 15, 22, 22, + 22, 22, 22, 22, 22, 22, 22, 22, 22, -1, + 22, -1, 78, 78, -1, -1, -1, 78, -1, 78, + 15, 78, 78, 78, -1, 78, 114, -1, 78, 114, + 114, 114, 78, 76, 76, -1, -1, 76, 76, 76, + 76, -1, 15, 15, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, 98, -1, 98, 98, 98, -1, -1, - 8, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, -1, -1, -1, 8, 8, -1, - -1, -1, -1, -1, -1, -1, -1, -1, 8, -1, - 8, -1, -1, 8, -1, -1, 8, 8, -1, 8, -1, -1, -1, -1, -1, -1, -1, -1, -1, -1, - -1, -1, -1, -1, 8, -1, 8 + -1, -1, -1, -1, -1, -1, 98, 98 ); protected $gotoBase = array( - 0, 0, -342, 0, 0, 212, 0, 196, 131, 0, - -150, 51, -85, -17, -146, -128, 245, 140, 174, 43, - 71, 0, 0, 1, 52, 0, -110, 0, 37, 0, - 53, 0, 4, -23, 0, 0, 208, -268, 0, -363, - 230, 0, 0, 0, 0, 0, 164, 0, 0, 106, - 0, 0, 248, 65, 64, 137, 90, 0, 0, 0, - 0, 0, 0, 111, 0, -35, 0, -43, 28, -195, - 0, -15, -21, -303, 0, 144, 39, 0, 0, 6, - -254, 0, 22, 0, 0, 168, -104, 0, 45, 59, - 55, 31, 0, -44, 0, 242, 0, 41, 139, 0, - 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, - 0, 0, -8, 0, 0, 17, 0, 0, 0, 49, - 0, 0, 0, -13, 0, 3, 0, 0, 9, 0, - 0, 0, 0, 0, 0, -78, -69, 231, -52, 0, - 58, 0, 26, 0, 243, 0, 0, 238, 120, -67, - 0, 0 + 0, 0, -276, 0, 0, 197, 186, 285, -11, 0, + 0, -87, 90, 9, -164, 53, -51, 39, 62, -100, + 0, -133, 154, 204, 446, 3, 168, 32, 48, 0, + 0, 0, 0, 0, -34, 0, 73, 0, 77, 0, + -2, -1, 0, 0, 192, -365, 0, -232, 183, 0, + 0, 0, 0, 0, 193, 0, 0, -23, 0, 0, + 237, 0, 67, 178, -229, 0, 0, 0, 0, 0, + 0, -6, 0, 0, -199, 0, 145, -173, 41, 0, + -19, -21, -376, 0, 70, 0, 0, 16, -280, 0, + 23, 0, 0, 0, 233, 257, 0, 0, 352, -58, + 0, 50, 0, 75, 0, -45, 0, -55, 0, 0, + 0, 2, 0, 51, 171, 0, 13, 0, 0, 0, + 0, 0, 0, 0, 0, 0, 0, 0, -262, 0, + 0, 12, 0, 260, 0, 45, 0, 0, 0, -189, + 0, 10, 0, 0, 7, 0, 0, 0, 0, 0, + 0, 58, 4, 94, 213, 127, 0, 0, 27, 0, + 34, 225, 0, 231, 86, -54, 0, 0 ); protected $gotoDefault = array( - -32768, 422, 607, 2, 608, 680, 688, 552, 439, 577, - 440, 466, 337, 762, 920, 782, 744, 745, 746, 322, - 363, 313, 320, 535, 522, 412, 731, 383, 723, 409, - 726, 382, 735, 140, 553, 418, 739, 1, 741, 472, - 773, 310, 749, 311, 556, 751, 479, 753, 754, 316, - 323, 324, 924, 488, 519, 766, 213, 481, 767, 309, - 768, 776, 333, 314, 394, 419, 328, 901, 506, 531, - 378, 397, 516, 511, 490, 1031, 801, 403, 392, 815, - 298, 823, 605, 831, 834, 441, 442, 401, 846, 402, - 860, 507, 508, 1039, 396, 866, 384, 873, 1071, 387, - 877, 228, 880, 255, 550, 351, 885, 886, 6, 891, - 568, 569, 7, 243, 417, 915, 551, 381, 930, 366, - 998, 1000, 474, 410, 1013, 391, 559, 420, 1018, 1075, - 379, 443, 398, 284, 302, 257, 444, 460, 264, 445, - 399, 1078, 1085, 340, 1101, 281, 26, 1113, 1122, 294, - 494, 513 + -32768, 482, 689, 4, 690, 763, 771, 566, 498, 659, + 325, 592, 390, 1209, 856, 1033, 548, 790, 1153, 1161, + 427, 793, 313, 327, 838, 839, 840, 367, 352, 358, + 365, 613, 593, 464, 825, 421, 817, 456, 820, 420, + 829, 158, 387, 480, 833, 3, 835, 525, 866, 353, + 843, 354, 636, 845, 533, 847, 848, 361, 368, 369, + 1038, 541, 589, 860, 237, 535, 861, 351, 862, 869, + 356, 359, 645, 436, 475, 381, 1014, 576, 610, 432, + 450, 599, 598, 586, 895, 457, 434, 909, 328, 917, + 687, 1045, 605, 459, 925, 606, 932, 935, 499, 500, + 449, 947, 268, 460, 974, 628, 629, 959, 608, 972, + 444, 978, 422, 986, 1197, 425, 990, 260, 993, 269, + 386, 401, 998, 999, 8, 1004, 651, 652, 10, 265, + 479, 1028, 646, 419, 1044, 406, 1113, 1115, 527, 461, + 1133, 1132, 639, 476, 1138, 1200, 416, 501, 445, 299, + 502, 290, 316, 296, 517, 277, 317, 503, 446, 1206, + 1214, 314, 29, 1234, 1245, 323, 545, 581 ); protected $ruleToNonTerminal = array( @@ -755,53 +836,57 @@ class Php7 extends \PhpParser\ParserAbstract 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, - 5, 5, 5, 5, 6, 6, 6, 6, 6, 6, - 6, 7, 7, 8, 9, 10, 10, 11, 12, 13, - 13, 14, 14, 15, 15, 4, 4, 4, 4, 4, - 4, 4, 4, 4, 4, 4, 20, 20, 21, 21, - 21, 21, 23, 25, 25, 19, 27, 27, 24, 29, - 29, 26, 26, 28, 28, 30, 30, 22, 31, 31, - 32, 34, 35, 35, 36, 37, 37, 39, 38, 38, - 38, 38, 40, 40, 40, 40, 40, 40, 40, 40, - 40, 40, 40, 40, 40, 40, 40, 40, 40, 40, - 40, 40, 40, 40, 40, 40, 40, 16, 16, 59, - 59, 62, 62, 61, 60, 60, 53, 64, 64, 65, - 65, 66, 66, 67, 67, 17, 18, 18, 18, 70, - 70, 70, 71, 71, 74, 74, 72, 72, 76, 77, - 77, 47, 47, 55, 55, 58, 58, 58, 57, 78, - 78, 79, 48, 48, 48, 48, 80, 80, 81, 81, - 82, 82, 45, 45, 41, 41, 83, 43, 43, 84, - 42, 42, 44, 44, 54, 54, 54, 54, 68, 68, - 87, 87, 88, 88, 88, 90, 90, 90, 91, 91, - 91, 92, 92, 89, 89, 69, 69, 69, 93, 93, - 94, 94, 95, 95, 95, 50, 96, 96, 97, 51, - 99, 99, 100, 100, 101, 101, 73, 102, 102, 102, - 102, 102, 107, 107, 108, 108, 109, 109, 109, 109, - 109, 110, 111, 111, 106, 106, 103, 103, 105, 105, - 113, 113, 112, 112, 112, 112, 112, 112, 104, 114, - 114, 116, 115, 115, 52, 117, 117, 46, 46, 33, - 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, - 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, - 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, - 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, - 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, - 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, - 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, - 33, 33, 33, 33, 33, 33, 33, 33, 33, 33, - 33, 33, 33, 33, 33, 124, 118, 118, 123, 123, - 126, 127, 127, 128, 129, 129, 129, 75, 75, 63, - 63, 63, 119, 119, 119, 131, 131, 120, 120, 122, - 122, 122, 125, 125, 136, 136, 136, 86, 138, 138, - 138, 121, 121, 121, 121, 121, 121, 121, 121, 121, - 121, 121, 121, 121, 121, 121, 121, 49, 49, 134, - 134, 134, 130, 130, 130, 139, 139, 139, 139, 139, - 139, 56, 56, 56, 98, 98, 98, 98, 142, 141, - 133, 133, 133, 133, 133, 133, 132, 132, 132, 140, - 140, 140, 140, 85, 143, 143, 144, 144, 144, 144, - 144, 144, 144, 137, 146, 146, 145, 145, 147, 147, - 147, 147, 147, 147, 135, 135, 135, 135, 149, 150, - 148, 148, 148, 148, 148, 148, 148, 151, 151, 151, - 151 + 5, 5, 5, 5, 5, 6, 6, 6, 6, 6, + 6, 6, 7, 7, 8, 9, 10, 10, 10, 11, + 11, 12, 12, 13, 14, 14, 15, 15, 16, 16, + 17, 17, 20, 20, 21, 22, 22, 23, 23, 4, + 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, + 28, 28, 29, 29, 31, 33, 33, 27, 35, 35, + 32, 37, 37, 34, 34, 36, 36, 38, 38, 30, + 39, 39, 40, 42, 43, 43, 44, 45, 45, 47, + 46, 46, 46, 46, 48, 48, 48, 48, 48, 48, + 48, 48, 48, 48, 48, 48, 48, 48, 48, 48, + 48, 48, 48, 48, 48, 48, 48, 48, 24, 24, + 67, 67, 70, 70, 69, 68, 68, 61, 73, 73, + 74, 74, 75, 75, 76, 76, 25, 25, 26, 26, + 26, 79, 79, 79, 80, 80, 83, 83, 81, 81, + 84, 85, 85, 55, 55, 63, 63, 66, 66, 66, + 65, 86, 86, 87, 56, 56, 56, 56, 88, 88, + 89, 89, 90, 90, 91, 92, 92, 93, 93, 94, + 94, 53, 53, 49, 49, 96, 51, 51, 97, 50, + 50, 52, 52, 62, 62, 62, 62, 77, 77, 100, + 100, 102, 102, 102, 102, 101, 101, 101, 104, 104, + 104, 105, 105, 107, 107, 107, 106, 106, 108, 108, + 109, 109, 109, 103, 103, 78, 78, 78, 19, 19, + 110, 110, 111, 111, 111, 111, 58, 112, 112, 113, + 59, 115, 115, 116, 116, 117, 117, 82, 118, 118, + 118, 118, 118, 123, 123, 124, 124, 125, 125, 125, + 125, 125, 126, 127, 127, 122, 122, 119, 119, 121, + 121, 129, 129, 128, 128, 128, 128, 128, 128, 120, + 130, 130, 132, 131, 131, 60, 95, 133, 133, 54, + 54, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 41, 41, 41, 41, 41, 41, 41, + 41, 41, 41, 140, 134, 134, 139, 139, 142, 143, + 143, 144, 145, 145, 145, 18, 18, 71, 71, 71, + 71, 135, 135, 135, 135, 147, 147, 136, 136, 138, + 138, 138, 141, 141, 152, 152, 152, 152, 152, 152, + 152, 152, 152, 153, 153, 99, 155, 155, 155, 155, + 137, 137, 137, 137, 137, 137, 137, 137, 57, 57, + 150, 150, 150, 150, 156, 156, 146, 146, 146, 157, + 157, 157, 157, 157, 157, 72, 72, 64, 64, 64, + 64, 114, 114, 114, 114, 160, 159, 149, 149, 149, + 149, 149, 149, 149, 148, 148, 148, 158, 158, 158, + 158, 98, 154, 162, 162, 161, 161, 163, 163, 163, + 163, 163, 163, 163, 163, 151, 151, 151, 151, 165, + 166, 164, 164, 164, 164, 164, 164, 164, 164, 167, + 167, 167, 167 ); protected $ruleToLength = array( @@ -813,52 +898,56 @@ class Php7 extends \PhpParser\ParserAbstract 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 3, 1, 1, 1, - 1, 0, 1, 0, 1, 1, 1, 1, 1, 3, - 5, 4, 3, 4, 2, 3, 1, 1, 7, 8, - 6, 7, 2, 3, 1, 2, 3, 1, 2, 3, - 1, 1, 3, 1, 2, 1, 2, 2, 3, 1, - 3, 2, 3, 1, 3, 2, 0, 1, 1, 1, - 1, 1, 3, 7, 10, 5, 7, 9, 5, 3, - 3, 3, 3, 3, 3, 1, 2, 5, 7, 9, - 6, 5, 6, 3, 3, 2, 1, 1, 1, 0, - 2, 1, 3, 8, 0, 4, 2, 1, 3, 0, - 1, 0, 1, 3, 1, 8, 7, 6, 5, 1, - 2, 2, 0, 2, 0, 2, 0, 2, 2, 1, - 3, 1, 4, 1, 4, 1, 1, 4, 2, 1, - 3, 3, 3, 4, 4, 5, 0, 2, 4, 3, - 1, 1, 1, 4, 0, 2, 5, 0, 2, 6, - 0, 2, 0, 3, 1, 2, 1, 1, 2, 0, - 1, 3, 4, 6, 4, 1, 2, 1, 1, 1, - 1, 3, 3, 0, 1, 0, 2, 2, 2, 4, - 1, 3, 1, 2, 2, 2, 3, 1, 1, 2, - 3, 1, 1, 3, 2, 0, 1, 4, 4, 9, - 3, 1, 1, 3, 0, 2, 4, 5, 4, 4, - 4, 3, 1, 1, 1, 1, 1, 1, 0, 1, - 1, 2, 1, 1, 1, 1, 1, 1, 2, 1, - 3, 1, 1, 3, 2, 3, 1, 0, 1, 1, - 3, 3, 3, 4, 1, 2, 3, 3, 3, 3, - 3, 3, 3, 3, 3, 3, 3, 3, 3, 2, - 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, - 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, - 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, - 3, 3, 3, 3, 3, 5, 4, 3, 4, 4, - 2, 2, 4, 2, 2, 2, 2, 2, 2, 2, - 2, 2, 2, 2, 1, 3, 2, 1, 2, 4, - 2, 8, 9, 8, 9, 7, 3, 2, 0, 4, - 2, 1, 3, 2, 2, 2, 4, 1, 1, 1, - 2, 3, 1, 1, 1, 1, 1, 0, 3, 0, - 1, 1, 0, 1, 1, 3, 3, 3, 4, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 3, 2, 3, 3, 0, 1, 1, - 3, 1, 1, 3, 1, 1, 4, 4, 4, 1, - 4, 1, 1, 3, 1, 4, 2, 2, 1, 3, - 1, 4, 4, 3, 3, 3, 1, 3, 1, 1, - 3, 1, 1, 4, 3, 1, 1, 2, 1, 3, - 4, 3, 0, 1, 1, 1, 3, 1, 3, 1, - 4, 2, 2, 0, 2, 2, 1, 2, 1, 1, - 1, 4, 3, 3, 3, 6, 3, 1, 1, 2, - 1 + 1, 1, 1, 1, 1, 1, 0, 1, 0, 1, + 1, 2, 1, 3, 4, 1, 2, 0, 1, 1, + 1, 1, 1, 3, 5, 4, 3, 4, 2, 3, + 1, 1, 7, 6, 2, 3, 1, 2, 3, 1, + 2, 3, 1, 1, 3, 1, 3, 1, 2, 2, + 3, 1, 3, 2, 3, 1, 3, 2, 0, 1, + 1, 1, 1, 1, 3, 7, 10, 5, 7, 9, + 5, 3, 3, 3, 3, 3, 3, 1, 2, 5, + 7, 9, 6, 5, 6, 3, 2, 1, 1, 1, + 0, 2, 1, 3, 8, 0, 4, 2, 1, 3, + 0, 1, 0, 1, 3, 1, 8, 9, 8, 7, + 6, 1, 2, 2, 0, 2, 0, 2, 0, 2, + 2, 1, 3, 1, 4, 1, 4, 1, 1, 4, + 2, 1, 3, 3, 3, 4, 4, 5, 0, 2, + 4, 3, 1, 1, 7, 0, 2, 1, 3, 3, + 4, 1, 4, 0, 2, 5, 0, 2, 6, 0, + 2, 0, 3, 1, 2, 1, 1, 2, 0, 1, + 3, 0, 1, 1, 1, 6, 8, 6, 1, 2, + 1, 1, 1, 1, 1, 1, 3, 3, 3, 3, + 1, 2, 1, 0, 1, 0, 2, 2, 2, 4, + 1, 3, 1, 2, 2, 3, 2, 3, 1, 1, + 2, 3, 1, 1, 3, 2, 0, 1, 5, 5, + 10, 3, 1, 1, 3, 0, 2, 4, 5, 4, + 4, 4, 3, 1, 1, 1, 1, 1, 1, 0, + 1, 1, 2, 1, 1, 1, 1, 1, 1, 2, + 1, 3, 1, 1, 3, 2, 2, 3, 1, 0, + 1, 1, 3, 3, 3, 4, 1, 1, 2, 3, + 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, + 3, 3, 2, 2, 2, 2, 3, 3, 3, 3, + 3, 3, 3, 3, 3, 3, 3, 3, 3, 3, + 3, 3, 3, 2, 2, 2, 2, 3, 3, 3, + 3, 3, 3, 3, 3, 3, 3, 3, 5, 4, + 3, 4, 4, 2, 2, 4, 2, 2, 2, 2, + 2, 2, 2, 2, 2, 2, 2, 1, 3, 2, + 1, 2, 4, 2, 2, 8, 9, 8, 9, 9, + 10, 9, 10, 8, 3, 2, 0, 4, 2, 1, + 3, 2, 2, 2, 4, 1, 1, 1, 1, 1, + 1, 1, 1, 3, 1, 1, 1, 0, 3, 0, + 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, + 1, 1, 1, 3, 3, 3, 4, 1, 1, 3, + 1, 1, 1, 1, 1, 3, 2, 3, 0, 1, + 1, 3, 1, 1, 1, 1, 1, 3, 1, 1, + 4, 4, 1, 4, 4, 0, 1, 1, 1, 3, + 3, 1, 4, 2, 2, 1, 3, 1, 4, 4, + 3, 3, 3, 3, 1, 3, 1, 1, 3, 1, + 1, 4, 1, 1, 1, 3, 1, 1, 2, 1, + 3, 4, 3, 2, 0, 2, 2, 1, 2, 1, + 1, 1, 4, 3, 3, 3, 3, 6, 3, 1, + 1, 2, 1 ); protected function initReduceCallbacks() { @@ -876,7 +965,7 @@ protected function initReduceCallbacks() { $this->semValue = array(); }, 4 => function ($stackPos) { - $startAttributes = $this->lookaheadStartAttributes; if (isset($startAttributes['comments'])) { $nop = new Stmt\Nop($this->createZeroLengthAttributes($startAttributes)); } else { $nop = null; }; + $startAttributes = $this->lookaheadStartAttributes; if (isset($startAttributes['comments'])) { $nop = new Stmt\Nop($this->createCommentNopAttributes($startAttributes['comments'])); } else { $nop = null; }; if ($nop !== null) { $this->semStack[$stackPos-(1-1)][] = $nop; } $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 5 => function ($stackPos) { @@ -1108,7 +1197,7 @@ protected function initReduceCallbacks() { $this->semValue = $this->semStack[$stackPos]; }, 81 => function ($stackPos) { - $this->semValue = new Node\Identifier($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos]; }, 82 => function ($stackPos) { $this->semValue = new Node\Identifier($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); @@ -1120,136 +1209,136 @@ protected function initReduceCallbacks() { $this->semValue = new Node\Identifier($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 85 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semValue = new Node\Identifier($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 86 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = new Name($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 87 => function ($stackPos) { $this->semValue = new Name($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 88 => function ($stackPos) { - $this->semValue = new Expr\Variable(substr($this->semStack[$stackPos-(1-1)], 1), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Name($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 89 => function ($stackPos) { - /* nothing */ + $this->semValue = new Name($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 90 => function ($stackPos) { - /* nothing */ + $this->semValue = new Name($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 91 => function ($stackPos) { - /* nothing */ + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 92 => function ($stackPos) { - $this->emitError(new Error('A trailing comma is not allowed here', $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes)); + $this->semValue = new Name(substr($this->semStack[$stackPos-(1-1)], 1), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 93 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos]; + $this->semValue = new Expr\Variable(substr($this->semStack[$stackPos-(1-1)], 1), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 94 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos]; + /* nothing */ }, 95 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + /* nothing */ }, 96 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + /* nothing */ }, 97 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->emitError(new Error('A trailing comma is not allowed here', $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes)); }, 98 => function ($stackPos) { - $this->semValue = new Stmt\HaltCompiler($this->lexer->handleHaltCompiler(), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos]; }, 99 => function ($stackPos) { - $this->semValue = new Stmt\Namespace_($this->semStack[$stackPos-(3-2)], null, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); - $this->semValue->setAttribute('kind', Stmt\Namespace_::KIND_SEMICOLON); - $this->checkNamespace($this->semValue); + $this->semValue = $this->semStack[$stackPos]; }, 100 => function ($stackPos) { - $this->semValue = new Stmt\Namespace_($this->semStack[$stackPos-(5-2)], $this->semStack[$stackPos-(5-4)], $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes); - $this->semValue->setAttribute('kind', Stmt\Namespace_::KIND_BRACED); - $this->checkNamespace($this->semValue); + $this->semValue = new Node\Attribute($this->semStack[$stackPos-(1-1)], [], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 101 => function ($stackPos) { - $this->semValue = new Stmt\Namespace_(null, $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); - $this->semValue->setAttribute('kind', Stmt\Namespace_::KIND_BRACED); - $this->checkNamespace($this->semValue); + $this->semValue = new Node\Attribute($this->semStack[$stackPos-(2-1)], $this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 102 => function ($stackPos) { - $this->semValue = new Stmt\Use_($this->semStack[$stackPos-(3-2)], Stmt\Use_::TYPE_NORMAL, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 103 => function ($stackPos) { - $this->semValue = new Stmt\Use_($this->semStack[$stackPos-(4-3)], $this->semStack[$stackPos-(4-2)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 104 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = new Node\AttributeGroup($this->semStack[$stackPos-(4-2)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 105 => function ($stackPos) { - $this->semValue = new Stmt\Const_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 106 => function ($stackPos) { - $this->semValue = Stmt\Use_::TYPE_FUNCTION; + $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 107 => function ($stackPos) { - $this->semValue = Stmt\Use_::TYPE_CONSTANT; + $this->semValue = []; }, 108 => function ($stackPos) { - $this->semValue = new Stmt\GroupUse(new Name($this->semStack[$stackPos-(7-3)], $this->startAttributeStack[$stackPos-(7-3)] + $this->endAttributeStack[$stackPos-(7-3)]), $this->semStack[$stackPos-(7-6)], $this->semStack[$stackPos-(7-2)], $this->startAttributeStack[$stackPos-(7-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 109 => function ($stackPos) { - $this->semValue = new Stmt\GroupUse(new Name($this->semStack[$stackPos-(8-4)], $this->startAttributeStack[$stackPos-(8-4)] + $this->endAttributeStack[$stackPos-(8-4)]), $this->semStack[$stackPos-(8-7)], $this->semStack[$stackPos-(8-2)], $this->startAttributeStack[$stackPos-(8-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 110 => function ($stackPos) { - $this->semValue = new Stmt\GroupUse(new Name($this->semStack[$stackPos-(6-2)], $this->startAttributeStack[$stackPos-(6-2)] + $this->endAttributeStack[$stackPos-(6-2)]), $this->semStack[$stackPos-(6-5)], Stmt\Use_::TYPE_UNKNOWN, $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 111 => function ($stackPos) { - $this->semValue = new Stmt\GroupUse(new Name($this->semStack[$stackPos-(7-3)], $this->startAttributeStack[$stackPos-(7-3)] + $this->endAttributeStack[$stackPos-(7-3)]), $this->semStack[$stackPos-(7-6)], Stmt\Use_::TYPE_UNKNOWN, $this->startAttributeStack[$stackPos-(7-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 112 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = new Stmt\HaltCompiler($this->lexer->handleHaltCompiler(), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 113 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = new Stmt\Namespace_($this->semStack[$stackPos-(3-2)], null, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue->setAttribute('kind', Stmt\Namespace_::KIND_SEMICOLON); + $this->checkNamespace($this->semValue); }, 114 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semValue = new Stmt\Namespace_($this->semStack[$stackPos-(5-2)], $this->semStack[$stackPos-(5-4)], $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes); + $this->semValue->setAttribute('kind', Stmt\Namespace_::KIND_BRACED); + $this->checkNamespace($this->semValue); }, 115 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = new Stmt\Namespace_(null, $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue->setAttribute('kind', Stmt\Namespace_::KIND_BRACED); + $this->checkNamespace($this->semValue); }, 116 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = new Stmt\Use_($this->semStack[$stackPos-(3-2)], Stmt\Use_::TYPE_NORMAL, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 117 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semValue = new Stmt\Use_($this->semStack[$stackPos-(4-3)], $this->semStack[$stackPos-(4-2)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 118 => function ($stackPos) { $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 119 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = new Stmt\Const_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 120 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semValue = Stmt\Use_::TYPE_FUNCTION; }, 121 => function ($stackPos) { - $this->semValue = new Stmt\UseUse($this->semStack[$stackPos-(1-1)], null, Stmt\Use_::TYPE_UNKNOWN, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); $this->checkUseUse($this->semValue, $stackPos-(1-1)); + $this->semValue = Stmt\Use_::TYPE_CONSTANT; }, 122 => function ($stackPos) { - $this->semValue = new Stmt\UseUse($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], Stmt\Use_::TYPE_UNKNOWN, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); $this->checkUseUse($this->semValue, $stackPos-(3-3)); + $this->semValue = new Stmt\GroupUse($this->semStack[$stackPos-(7-3)], $this->semStack[$stackPos-(7-6)], $this->semStack[$stackPos-(7-2)], $this->startAttributeStack[$stackPos-(7-1)] + $this->endAttributes); }, 123 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Stmt\GroupUse($this->semStack[$stackPos-(6-2)], $this->semStack[$stackPos-(6-5)], Stmt\Use_::TYPE_UNKNOWN, $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); }, 124 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-2)]; + $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 125 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; $this->semValue->type = Stmt\Use_::TYPE_NORMAL; + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 126 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-2)]; $this->semValue->type = $this->semStack[$stackPos-(2-1)]; + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 127 => function ($stackPos) { $this->semValue = $this->semStack[$stackPos-(2-1)]; @@ -1261,1020 +1350,1028 @@ protected function initReduceCallbacks() { $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 130 => function ($stackPos) { - $this->semValue = new Node\Const_($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 131 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 132 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 133 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semValue = new Stmt\UseUse($this->semStack[$stackPos-(1-1)], null, Stmt\Use_::TYPE_UNKNOWN, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); $this->checkUseUse($this->semValue, $stackPos-(1-1)); }, 134 => function ($stackPos) { - $this->semValue = new Node\Const_($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Stmt\UseUse($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], Stmt\Use_::TYPE_UNKNOWN, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); $this->checkUseUse($this->semValue, $stackPos-(3-3)); }, 135 => function ($stackPos) { - if (is_array($this->semStack[$stackPos-(2-2)])) { $this->semValue = array_merge($this->semStack[$stackPos-(2-1)], $this->semStack[$stackPos-(2-2)]); } else { $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; }; + $this->semValue = new Stmt\UseUse($this->semStack[$stackPos-(1-1)], null, Stmt\Use_::TYPE_UNKNOWN, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); $this->checkUseUse($this->semValue, $stackPos-(1-1)); }, 136 => function ($stackPos) { - $this->semValue = array(); + $this->semValue = new Stmt\UseUse($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], Stmt\Use_::TYPE_UNKNOWN, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); $this->checkUseUse($this->semValue, $stackPos-(3-3)); }, 137 => function ($stackPos) { - $startAttributes = $this->lookaheadStartAttributes; if (isset($startAttributes['comments'])) { $nop = new Stmt\Nop($this->createZeroLengthAttributes($startAttributes)); } else { $nop = null; }; - if ($nop !== null) { $this->semStack[$stackPos-(1-1)][] = $nop; } $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = $this->semStack[$stackPos-(1-1)]; $this->semValue->type = Stmt\Use_::TYPE_NORMAL; }, 138 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = $this->semStack[$stackPos-(2-2)]; $this->semValue->type = $this->semStack[$stackPos-(2-1)]; }, 139 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 140 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 141 => function ($stackPos) { - throw new Error('__HALT_COMPILER() can only be used from the outermost scope', $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 142 => function ($stackPos) { - - if ($this->semStack[$stackPos-(3-2)]) { - $this->semValue = $this->semStack[$stackPos-(3-2)]; $attrs = $this->startAttributeStack[$stackPos-(3-1)]; $stmts = $this->semValue; if (!empty($attrs['comments'])) {$stmts[0]->setAttribute('comments', array_merge($attrs['comments'], $stmts[0]->getAttribute('comments', []))); }; - } else { - $startAttributes = $this->startAttributeStack[$stackPos-(3-1)]; if (isset($startAttributes['comments'])) { $this->semValue = new Stmt\Nop($startAttributes + $this->endAttributes); } else { $this->semValue = null; }; - if (null === $this->semValue) { $this->semValue = array(); } - } - + $this->semValue = new Node\Const_($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 143 => function ($stackPos) { - $this->semValue = new Stmt\If_($this->semStack[$stackPos-(7-3)], ['stmts' => is_array($this->semStack[$stackPos-(7-5)]) ? $this->semStack[$stackPos-(7-5)] : array($this->semStack[$stackPos-(7-5)]), 'elseifs' => $this->semStack[$stackPos-(7-6)], 'else' => $this->semStack[$stackPos-(7-7)]], $this->startAttributeStack[$stackPos-(7-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 144 => function ($stackPos) { - $this->semValue = new Stmt\If_($this->semStack[$stackPos-(10-3)], ['stmts' => $this->semStack[$stackPos-(10-6)], 'elseifs' => $this->semStack[$stackPos-(10-7)], 'else' => $this->semStack[$stackPos-(10-8)]], $this->startAttributeStack[$stackPos-(10-1)] + $this->endAttributes); + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 145 => function ($stackPos) { - $this->semValue = new Stmt\While_($this->semStack[$stackPos-(5-3)], $this->semStack[$stackPos-(5-5)], $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes); + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 146 => function ($stackPos) { - $this->semValue = new Stmt\Do_($this->semStack[$stackPos-(7-5)], is_array($this->semStack[$stackPos-(7-2)]) ? $this->semStack[$stackPos-(7-2)] : array($this->semStack[$stackPos-(7-2)]), $this->startAttributeStack[$stackPos-(7-1)] + $this->endAttributes); + $this->semValue = new Node\Const_($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 147 => function ($stackPos) { - $this->semValue = new Stmt\For_(['init' => $this->semStack[$stackPos-(9-3)], 'cond' => $this->semStack[$stackPos-(9-5)], 'loop' => $this->semStack[$stackPos-(9-7)], 'stmts' => $this->semStack[$stackPos-(9-9)]], $this->startAttributeStack[$stackPos-(9-1)] + $this->endAttributes); + if (is_array($this->semStack[$stackPos-(2-2)])) { $this->semValue = array_merge($this->semStack[$stackPos-(2-1)], $this->semStack[$stackPos-(2-2)]); } else { $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; }; }, 148 => function ($stackPos) { - $this->semValue = new Stmt\Switch_($this->semStack[$stackPos-(5-3)], $this->semStack[$stackPos-(5-5)], $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes); + $this->semValue = array(); }, 149 => function ($stackPos) { - $this->semValue = new Stmt\Break_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $startAttributes = $this->lookaheadStartAttributes; if (isset($startAttributes['comments'])) { $nop = new Stmt\Nop($this->createCommentNopAttributes($startAttributes['comments'])); } else { $nop = null; }; + if ($nop !== null) { $this->semStack[$stackPos-(1-1)][] = $nop; } $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 150 => function ($stackPos) { - $this->semValue = new Stmt\Continue_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 151 => function ($stackPos) { - $this->semValue = new Stmt\Return_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 152 => function ($stackPos) { - $this->semValue = new Stmt\Global_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 153 => function ($stackPos) { - $this->semValue = new Stmt\Static_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + throw new Error('__HALT_COMPILER() can only be used from the outermost scope', $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 154 => function ($stackPos) { - $this->semValue = new Stmt\Echo_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + + if ($this->semStack[$stackPos-(3-2)]) { + $this->semValue = $this->semStack[$stackPos-(3-2)]; $attrs = $this->startAttributeStack[$stackPos-(3-1)]; $stmts = $this->semValue; if (!empty($attrs['comments'])) {$stmts[0]->setAttribute('comments', array_merge($attrs['comments'], $stmts[0]->getAttribute('comments', []))); }; + } else { + $startAttributes = $this->startAttributeStack[$stackPos-(3-1)]; if (isset($startAttributes['comments'])) { $this->semValue = new Stmt\Nop($startAttributes + $this->endAttributes); } else { $this->semValue = null; }; + if (null === $this->semValue) { $this->semValue = array(); } + } + }, 155 => function ($stackPos) { - $this->semValue = new Stmt\InlineHTML($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Stmt\If_($this->semStack[$stackPos-(7-3)], ['stmts' => is_array($this->semStack[$stackPos-(7-5)]) ? $this->semStack[$stackPos-(7-5)] : array($this->semStack[$stackPos-(7-5)]), 'elseifs' => $this->semStack[$stackPos-(7-6)], 'else' => $this->semStack[$stackPos-(7-7)]], $this->startAttributeStack[$stackPos-(7-1)] + $this->endAttributes); }, 156 => function ($stackPos) { - $this->semValue = new Stmt\Expression($this->semStack[$stackPos-(2-1)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Stmt\If_($this->semStack[$stackPos-(10-3)], ['stmts' => $this->semStack[$stackPos-(10-6)], 'elseifs' => $this->semStack[$stackPos-(10-7)], 'else' => $this->semStack[$stackPos-(10-8)]], $this->startAttributeStack[$stackPos-(10-1)] + $this->endAttributes); }, 157 => function ($stackPos) { - $this->semValue = new Stmt\Unset_($this->semStack[$stackPos-(5-3)], $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes); + $this->semValue = new Stmt\While_($this->semStack[$stackPos-(5-3)], $this->semStack[$stackPos-(5-5)], $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes); }, 158 => function ($stackPos) { - $this->semValue = new Stmt\Foreach_($this->semStack[$stackPos-(7-3)], $this->semStack[$stackPos-(7-5)][0], ['keyVar' => null, 'byRef' => $this->semStack[$stackPos-(7-5)][1], 'stmts' => $this->semStack[$stackPos-(7-7)]], $this->startAttributeStack[$stackPos-(7-1)] + $this->endAttributes); + $this->semValue = new Stmt\Do_($this->semStack[$stackPos-(7-5)], is_array($this->semStack[$stackPos-(7-2)]) ? $this->semStack[$stackPos-(7-2)] : array($this->semStack[$stackPos-(7-2)]), $this->startAttributeStack[$stackPos-(7-1)] + $this->endAttributes); }, 159 => function ($stackPos) { - $this->semValue = new Stmt\Foreach_($this->semStack[$stackPos-(9-3)], $this->semStack[$stackPos-(9-7)][0], ['keyVar' => $this->semStack[$stackPos-(9-5)], 'byRef' => $this->semStack[$stackPos-(9-7)][1], 'stmts' => $this->semStack[$stackPos-(9-9)]], $this->startAttributeStack[$stackPos-(9-1)] + $this->endAttributes); + $this->semValue = new Stmt\For_(['init' => $this->semStack[$stackPos-(9-3)], 'cond' => $this->semStack[$stackPos-(9-5)], 'loop' => $this->semStack[$stackPos-(9-7)], 'stmts' => $this->semStack[$stackPos-(9-9)]], $this->startAttributeStack[$stackPos-(9-1)] + $this->endAttributes); }, 160 => function ($stackPos) { - $this->semValue = new Stmt\Foreach_($this->semStack[$stackPos-(6-3)], new Expr\Error($this->startAttributeStack[$stackPos-(6-4)] + $this->endAttributeStack[$stackPos-(6-4)]), ['stmts' => $this->semStack[$stackPos-(6-6)]], $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); + $this->semValue = new Stmt\Switch_($this->semStack[$stackPos-(5-3)], $this->semStack[$stackPos-(5-5)], $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes); }, 161 => function ($stackPos) { - $this->semValue = new Stmt\Declare_($this->semStack[$stackPos-(5-3)], $this->semStack[$stackPos-(5-5)], $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes); + $this->semValue = new Stmt\Break_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 162 => function ($stackPos) { - $this->semValue = new Stmt\TryCatch($this->semStack[$stackPos-(6-3)], $this->semStack[$stackPos-(6-5)], $this->semStack[$stackPos-(6-6)], $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); $this->checkTryCatch($this->semValue); + $this->semValue = new Stmt\Continue_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 163 => function ($stackPos) { - $this->semValue = new Stmt\Throw_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Stmt\Return_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 164 => function ($stackPos) { - $this->semValue = new Stmt\Goto_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Stmt\Global_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 165 => function ($stackPos) { - $this->semValue = new Stmt\Label($this->semStack[$stackPos-(2-1)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Stmt\Static_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 166 => function ($stackPos) { - $this->semValue = array(); /* means: no statement */ + $this->semValue = new Stmt\Echo_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 167 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Stmt\InlineHTML($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 168 => function ($stackPos) { - $startAttributes = $this->startAttributeStack[$stackPos-(1-1)]; if (isset($startAttributes['comments'])) { $this->semValue = new Stmt\Nop($startAttributes + $this->endAttributes); } else { $this->semValue = null; }; - if ($this->semValue === null) $this->semValue = array(); /* means: no statement */ + + $e = $this->semStack[$stackPos-(2-1)]; + if ($e instanceof Expr\Throw_) { + // For backwards-compatibility reasons, convert throw in statement position into + // Stmt\Throw_ rather than Stmt\Expression(Expr\Throw_). + $this->semValue = new Stmt\Throw_($e->expr, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + } else { + $this->semValue = new Stmt\Expression($e, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + } + }, 169 => function ($stackPos) { - $this->semValue = array(); + $this->semValue = new Stmt\Unset_($this->semStack[$stackPos-(5-3)], $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes); }, 170 => function ($stackPos) { - $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = new Stmt\Foreach_($this->semStack[$stackPos-(7-3)], $this->semStack[$stackPos-(7-5)][0], ['keyVar' => null, 'byRef' => $this->semStack[$stackPos-(7-5)][1], 'stmts' => $this->semStack[$stackPos-(7-7)]], $this->startAttributeStack[$stackPos-(7-1)] + $this->endAttributes); }, 171 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semValue = new Stmt\Foreach_($this->semStack[$stackPos-(9-3)], $this->semStack[$stackPos-(9-7)][0], ['keyVar' => $this->semStack[$stackPos-(9-5)], 'byRef' => $this->semStack[$stackPos-(9-7)][1], 'stmts' => $this->semStack[$stackPos-(9-9)]], $this->startAttributeStack[$stackPos-(9-1)] + $this->endAttributes); }, 172 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = new Stmt\Foreach_($this->semStack[$stackPos-(6-3)], new Expr\Error($this->startAttributeStack[$stackPos-(6-4)] + $this->endAttributeStack[$stackPos-(6-4)]), ['stmts' => $this->semStack[$stackPos-(6-6)]], $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); }, 173 => function ($stackPos) { - $this->semValue = new Stmt\Catch_($this->semStack[$stackPos-(8-3)], $this->semStack[$stackPos-(8-4)], $this->semStack[$stackPos-(8-7)], $this->startAttributeStack[$stackPos-(8-1)] + $this->endAttributes); + $this->semValue = new Stmt\Declare_($this->semStack[$stackPos-(5-3)], $this->semStack[$stackPos-(5-5)], $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes); }, 174 => function ($stackPos) { - $this->semValue = null; + $this->semValue = new Stmt\TryCatch($this->semStack[$stackPos-(6-3)], $this->semStack[$stackPos-(6-5)], $this->semStack[$stackPos-(6-6)], $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); $this->checkTryCatch($this->semValue); }, 175 => function ($stackPos) { - $this->semValue = new Stmt\Finally_($this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = new Stmt\Goto_($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 176 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = new Stmt\Label($this->semStack[$stackPos-(2-1)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 177 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semValue = array(); /* means: no statement */ }, 178 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 179 => function ($stackPos) { - $this->semValue = false; + $startAttributes = $this->startAttributeStack[$stackPos-(1-1)]; if (isset($startAttributes['comments'])) { $this->semValue = new Stmt\Nop($startAttributes + $this->endAttributes); } else { $this->semValue = null; }; + if ($this->semValue === null) $this->semValue = array(); /* means: no statement */ }, 180 => function ($stackPos) { - $this->semValue = true; + $this->semValue = array(); }, 181 => function ($stackPos) { - $this->semValue = false; + $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 182 => function ($stackPos) { - $this->semValue = true; + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 183 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(3-2)]; + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 184 => function ($stackPos) { - $this->semValue = []; + $this->semValue = new Stmt\Catch_($this->semStack[$stackPos-(8-3)], $this->semStack[$stackPos-(8-4)], $this->semStack[$stackPos-(8-7)], $this->startAttributeStack[$stackPos-(8-1)] + $this->endAttributes); }, 185 => function ($stackPos) { - $this->semValue = new Stmt\Function_($this->semStack[$stackPos-(8-3)], ['byRef' => $this->semStack[$stackPos-(8-2)], 'params' => $this->semStack[$stackPos-(8-5)], 'returnType' => $this->semStack[$stackPos-(8-7)], 'stmts' => $this->semStack[$stackPos-(8-8)]], $this->startAttributeStack[$stackPos-(8-1)] + $this->endAttributes); + $this->semValue = null; }, 186 => function ($stackPos) { - $this->semValue = new Stmt\Class_($this->semStack[$stackPos-(7-2)], ['type' => $this->semStack[$stackPos-(7-1)], 'extends' => $this->semStack[$stackPos-(7-3)], 'implements' => $this->semStack[$stackPos-(7-4)], 'stmts' => $this->semStack[$stackPos-(7-6)]], $this->startAttributeStack[$stackPos-(7-1)] + $this->endAttributes); - $this->checkClass($this->semValue, $stackPos-(7-2)); + $this->semValue = new Stmt\Finally_($this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 187 => function ($stackPos) { - $this->semValue = new Stmt\Interface_($this->semStack[$stackPos-(6-2)], ['extends' => $this->semStack[$stackPos-(6-3)], 'stmts' => $this->semStack[$stackPos-(6-5)]], $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); - $this->checkInterface($this->semValue, $stackPos-(6-2)); + $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 188 => function ($stackPos) { - $this->semValue = new Stmt\Trait_($this->semStack[$stackPos-(5-2)], ['stmts' => $this->semStack[$stackPos-(5-4)]], $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes); + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 189 => function ($stackPos) { - $this->semValue = 0; + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 190 => function ($stackPos) { - $this->semValue = Stmt\Class_::MODIFIER_ABSTRACT; + $this->semValue = false; }, 191 => function ($stackPos) { - $this->semValue = Stmt\Class_::MODIFIER_FINAL; + $this->semValue = true; }, 192 => function ($stackPos) { - $this->semValue = null; + $this->semValue = false; }, 193 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-2)]; + $this->semValue = true; }, 194 => function ($stackPos) { - $this->semValue = array(); + $this->semValue = $this->semStack[$stackPos-(3-2)]; }, 195 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-2)]; + $this->semValue = []; }, 196 => function ($stackPos) { - $this->semValue = array(); + $this->semValue = new Stmt\Function_($this->semStack[$stackPos-(8-3)], ['byRef' => $this->semStack[$stackPos-(8-2)], 'params' => $this->semStack[$stackPos-(8-5)], 'returnType' => $this->semStack[$stackPos-(8-7)], 'stmts' => $this->semStack[$stackPos-(8-8)], 'attrGroups' => []], $this->startAttributeStack[$stackPos-(8-1)] + $this->endAttributes); }, 197 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-2)]; + $this->semValue = new Stmt\Function_($this->semStack[$stackPos-(9-4)], ['byRef' => $this->semStack[$stackPos-(9-3)], 'params' => $this->semStack[$stackPos-(9-6)], 'returnType' => $this->semStack[$stackPos-(9-8)], 'stmts' => $this->semStack[$stackPos-(9-9)], 'attrGroups' => $this->semStack[$stackPos-(9-1)]], $this->startAttributeStack[$stackPos-(9-1)] + $this->endAttributes); }, 198 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = new Stmt\Class_($this->semStack[$stackPos-(8-3)], ['type' => $this->semStack[$stackPos-(8-2)], 'extends' => $this->semStack[$stackPos-(8-4)], 'implements' => $this->semStack[$stackPos-(8-5)], 'stmts' => $this->semStack[$stackPos-(8-7)], 'attrGroups' => $this->semStack[$stackPos-(8-1)]], $this->startAttributeStack[$stackPos-(8-1)] + $this->endAttributes); + $this->checkClass($this->semValue, $stackPos-(8-3)); }, 199 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semValue = new Stmt\Interface_($this->semStack[$stackPos-(7-3)], ['extends' => $this->semStack[$stackPos-(7-4)], 'stmts' => $this->semStack[$stackPos-(7-6)], 'attrGroups' => $this->semStack[$stackPos-(7-1)]], $this->startAttributeStack[$stackPos-(7-1)] + $this->endAttributes); + $this->checkInterface($this->semValue, $stackPos-(7-3)); }, 200 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = new Stmt\Trait_($this->semStack[$stackPos-(6-3)], ['stmts' => $this->semStack[$stackPos-(6-5)], 'attrGroups' => $this->semStack[$stackPos-(6-1)]], $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); }, 201 => function ($stackPos) { - $this->semValue = is_array($this->semStack[$stackPos-(1-1)]) ? $this->semStack[$stackPos-(1-1)] : array($this->semStack[$stackPos-(1-1)]); + $this->semValue = 0; }, 202 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(4-2)]; + $this->semValue = Stmt\Class_::MODIFIER_ABSTRACT; }, 203 => function ($stackPos) { - $this->semValue = is_array($this->semStack[$stackPos-(1-1)]) ? $this->semStack[$stackPos-(1-1)] : array($this->semStack[$stackPos-(1-1)]); + $this->semValue = Stmt\Class_::MODIFIER_FINAL; }, 204 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(4-2)]; + $this->semValue = null; }, 205 => function ($stackPos) { - $this->semValue = is_array($this->semStack[$stackPos-(1-1)]) ? $this->semStack[$stackPos-(1-1)] : array($this->semStack[$stackPos-(1-1)]); + $this->semValue = $this->semStack[$stackPos-(2-2)]; }, 206 => function ($stackPos) { - $this->semValue = null; + $this->semValue = array(); }, 207 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(4-2)]; + $this->semValue = $this->semStack[$stackPos-(2-2)]; }, 208 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = array(); }, 209 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semValue = $this->semStack[$stackPos-(2-2)]; }, 210 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 211 => function ($stackPos) { - $this->semValue = new Stmt\DeclareDeclare($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 212 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(3-2)]; + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 213 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(4-3)]; + $this->semValue = is_array($this->semStack[$stackPos-(1-1)]) ? $this->semStack[$stackPos-(1-1)] : array($this->semStack[$stackPos-(1-1)]); }, 214 => function ($stackPos) { $this->semValue = $this->semStack[$stackPos-(4-2)]; }, 215 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(5-3)]; + $this->semValue = is_array($this->semStack[$stackPos-(1-1)]) ? $this->semStack[$stackPos-(1-1)] : array($this->semStack[$stackPos-(1-1)]); }, 216 => function ($stackPos) { - $this->semValue = array(); + $this->semValue = $this->semStack[$stackPos-(4-2)]; }, 217 => function ($stackPos) { - $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = is_array($this->semStack[$stackPos-(1-1)]) ? $this->semStack[$stackPos-(1-1)] : array($this->semStack[$stackPos-(1-1)]); }, 218 => function ($stackPos) { - $this->semValue = new Stmt\Case_($this->semStack[$stackPos-(4-2)], $this->semStack[$stackPos-(4-4)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = null; }, 219 => function ($stackPos) { - $this->semValue = new Stmt\Case_(null, $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(4-2)]; }, 220 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos]; + $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 221 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos]; + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 222 => function ($stackPos) { - $this->semValue = is_array($this->semStack[$stackPos-(1-1)]) ? $this->semStack[$stackPos-(1-1)] : array($this->semStack[$stackPos-(1-1)]); + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 223 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(4-2)]; + $this->semValue = new Stmt\DeclareDeclare($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 224 => function ($stackPos) { - $this->semValue = array(); + $this->semValue = $this->semStack[$stackPos-(3-2)]; }, 225 => function ($stackPos) { - $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = $this->semStack[$stackPos-(4-3)]; }, 226 => function ($stackPos) { - $this->semValue = new Stmt\ElseIf_($this->semStack[$stackPos-(5-3)], is_array($this->semStack[$stackPos-(5-5)]) ? $this->semStack[$stackPos-(5-5)] : array($this->semStack[$stackPos-(5-5)]), $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(4-2)]; }, 227 => function ($stackPos) { - $this->semValue = array(); + $this->semValue = $this->semStack[$stackPos-(5-3)]; }, 228 => function ($stackPos) { - $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = array(); }, 229 => function ($stackPos) { - $this->semValue = new Stmt\ElseIf_($this->semStack[$stackPos-(6-3)], $this->semStack[$stackPos-(6-6)], $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); + $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 230 => function ($stackPos) { - $this->semValue = null; + $this->semValue = new Stmt\Case_($this->semStack[$stackPos-(4-2)], $this->semStack[$stackPos-(4-4)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 231 => function ($stackPos) { - $this->semValue = new Stmt\Else_(is_array($this->semStack[$stackPos-(2-2)]) ? $this->semStack[$stackPos-(2-2)] : array($this->semStack[$stackPos-(2-2)]), $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Stmt\Case_(null, $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 232 => function ($stackPos) { - $this->semValue = null; + $this->semValue = $this->semStack[$stackPos]; }, 233 => function ($stackPos) { - $this->semValue = new Stmt\Else_($this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos]; }, 234 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)], false); + $this->semValue = new Expr\Match_($this->semStack[$stackPos-(7-3)], $this->semStack[$stackPos-(7-6)], $this->startAttributeStack[$stackPos-(7-1)] + $this->endAttributes); }, 235 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(2-2)], true); + $this->semValue = []; }, 236 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)], false); + $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 237 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)], false); + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 238 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 239 => function ($stackPos) { - $this->semValue = array(); + $this->semValue = new Node\MatchArm($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 240 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semValue = new Node\MatchArm(null, $this->semStack[$stackPos-(4-4)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 241 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = is_array($this->semStack[$stackPos-(1-1)]) ? $this->semStack[$stackPos-(1-1)] : array($this->semStack[$stackPos-(1-1)]); }, 242 => function ($stackPos) { - $this->semValue = new Node\Param($this->semStack[$stackPos-(4-4)], null, $this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-2)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); $this->checkParam($this->semValue); + $this->semValue = $this->semStack[$stackPos-(4-2)]; }, 243 => function ($stackPos) { - $this->semValue = new Node\Param($this->semStack[$stackPos-(6-4)], $this->semStack[$stackPos-(6-6)], $this->semStack[$stackPos-(6-1)], $this->semStack[$stackPos-(6-2)], $this->semStack[$stackPos-(6-3)], $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); $this->checkParam($this->semValue); + $this->semValue = array(); }, 244 => function ($stackPos) { - $this->semValue = new Node\Param(new Expr\Error($this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes), null, $this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-2)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 245 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Stmt\ElseIf_($this->semStack[$stackPos-(5-3)], is_array($this->semStack[$stackPos-(5-5)]) ? $this->semStack[$stackPos-(5-5)] : array($this->semStack[$stackPos-(5-5)]), $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes); }, 246 => function ($stackPos) { - $this->semValue = new Node\NullableType($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = array(); }, 247 => function ($stackPos) { - $this->semValue = new Node\UnionType($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 248 => function ($stackPos) { - $this->semValue = $this->handleBuiltinTypes($this->semStack[$stackPos-(1-1)]); + $this->semValue = new Stmt\ElseIf_($this->semStack[$stackPos-(6-3)], $this->semStack[$stackPos-(6-6)], $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); }, 249 => function ($stackPos) { - $this->semValue = new Node\Identifier('array', $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = null; }, 250 => function ($stackPos) { - $this->semValue = new Node\Identifier('callable', $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Stmt\Else_(is_array($this->semStack[$stackPos-(2-2)]) ? $this->semStack[$stackPos-(2-2)] : array($this->semStack[$stackPos-(2-2)]), $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 251 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)]); + $this->semValue = null; }, 252 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = new Stmt\Else_($this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 253 => function ($stackPos) { - $this->semValue = null; + $this->semValue = array($this->semStack[$stackPos-(1-1)], false); }, 254 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = array($this->semStack[$stackPos-(2-2)], true); }, 255 => function ($stackPos) { - $this->semValue = null; + $this->semValue = array($this->semStack[$stackPos-(1-1)], false); }, 256 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-2)]; + $this->semValue = array($this->semStack[$stackPos-(1-1)], false); }, 257 => function ($stackPos) { - $this->semValue = null; + $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 258 => function ($stackPos) { $this->semValue = array(); }, 259 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(4-2)]; + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 260 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 261 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = 0; }, 262 => function ($stackPos) { - $this->semValue = new Node\Arg($this->semStack[$stackPos-(1-1)], false, false, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = Stmt\Class_::MODIFIER_PUBLIC; }, 263 => function ($stackPos) { - $this->semValue = new Node\Arg($this->semStack[$stackPos-(2-2)], true, false, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = Stmt\Class_::MODIFIER_PROTECTED; }, 264 => function ($stackPos) { - $this->semValue = new Node\Arg($this->semStack[$stackPos-(2-2)], false, true, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = Stmt\Class_::MODIFIER_PRIVATE; }, 265 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = new Node\Param($this->semStack[$stackPos-(6-6)], null, $this->semStack[$stackPos-(6-3)], $this->semStack[$stackPos-(6-4)], $this->semStack[$stackPos-(6-5)], $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes, $this->semStack[$stackPos-(6-2)], $this->semStack[$stackPos-(6-1)]); + $this->checkParam($this->semValue); }, 266 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = new Node\Param($this->semStack[$stackPos-(8-6)], $this->semStack[$stackPos-(8-8)], $this->semStack[$stackPos-(8-3)], $this->semStack[$stackPos-(8-4)], $this->semStack[$stackPos-(8-5)], $this->startAttributeStack[$stackPos-(8-1)] + $this->endAttributes, $this->semStack[$stackPos-(8-2)], $this->semStack[$stackPos-(8-1)]); + $this->checkParam($this->semValue); }, 267 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semValue = new Node\Param(new Expr\Error($this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes), null, $this->semStack[$stackPos-(6-3)], $this->semStack[$stackPos-(6-4)], $this->semStack[$stackPos-(6-5)], $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes, $this->semStack[$stackPos-(6-2)], $this->semStack[$stackPos-(6-1)]); }, 268 => function ($stackPos) { - $this->semValue = new Expr\Variable($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 269 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = new Node\NullableType($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 270 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = new Node\UnionType($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 271 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 272 => function ($stackPos) { - $this->semValue = new Stmt\StaticVar($this->semStack[$stackPos-(1-1)], null, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Node\Name('static', $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 273 => function ($stackPos) { - $this->semValue = new Stmt\StaticVar($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->handleBuiltinTypes($this->semStack[$stackPos-(1-1)]); }, 274 => function ($stackPos) { - if ($this->semStack[$stackPos-(2-2)] !== null) { $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; } + $this->semValue = new Node\Identifier('array', $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 275 => function ($stackPos) { - $this->semValue = array(); + $this->semValue = new Node\Identifier('callable', $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 276 => function ($stackPos) { - $startAttributes = $this->lookaheadStartAttributes; if (isset($startAttributes['comments'])) { $nop = new Stmt\Nop($this->createZeroLengthAttributes($startAttributes)); } else { $nop = null; }; - if ($nop !== null) { $this->semStack[$stackPos-(1-1)][] = $nop; } $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = array($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)]); }, 277 => function ($stackPos) { - $attrs = $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes; - $this->semValue = new Stmt\Property($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $attrs, $this->semStack[$stackPos-(4-2)]); $this->checkProperty($this->semValue, $stackPos-(4-1)); + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 278 => function ($stackPos) { - $this->semValue = new Stmt\ClassConst($this->semStack[$stackPos-(4-3)], $this->semStack[$stackPos-(4-1)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); $this->checkClassConst($this->semValue, $stackPos-(4-1)); + $this->semValue = array($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)]); }, 279 => function ($stackPos) { - $this->semValue = new Stmt\ClassMethod($this->semStack[$stackPos-(9-4)], ['type' => $this->semStack[$stackPos-(9-1)], 'byRef' => $this->semStack[$stackPos-(9-3)], 'params' => $this->semStack[$stackPos-(9-6)], 'returnType' => $this->semStack[$stackPos-(9-8)], 'stmts' => $this->semStack[$stackPos-(9-9)]], $this->startAttributeStack[$stackPos-(9-1)] + $this->endAttributes); - $this->checkClassMethod($this->semValue, $stackPos-(9-1)); + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 280 => function ($stackPos) { - $this->semValue = new Stmt\TraitUse($this->semStack[$stackPos-(3-2)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 281 => function ($stackPos) { - $this->semValue = null; /* will be skipped */ + $this->semValue = new Node\NullableType($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 282 => function ($stackPos) { - $this->semValue = array(); + $this->semValue = new Node\UnionType($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 283 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(3-2)]; + $this->semValue = null; }, 284 => function ($stackPos) { - $this->semValue = array(); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 285 => function ($stackPos) { - $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = null; }, 286 => function ($stackPos) { - $this->semValue = new Stmt\TraitUseAdaptation\Precedence($this->semStack[$stackPos-(4-1)][0], $this->semStack[$stackPos-(4-1)][1], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(2-2)]; }, 287 => function ($stackPos) { - $this->semValue = new Stmt\TraitUseAdaptation\Alias($this->semStack[$stackPos-(5-1)][0], $this->semStack[$stackPos-(5-1)][1], $this->semStack[$stackPos-(5-3)], $this->semStack[$stackPos-(5-4)], $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes); + $this->semValue = null; }, 288 => function ($stackPos) { - $this->semValue = new Stmt\TraitUseAdaptation\Alias($this->semStack[$stackPos-(4-1)][0], $this->semStack[$stackPos-(4-1)][1], $this->semStack[$stackPos-(4-3)], null, $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = array(); }, 289 => function ($stackPos) { - $this->semValue = new Stmt\TraitUseAdaptation\Alias($this->semStack[$stackPos-(4-1)][0], $this->semStack[$stackPos-(4-1)][1], null, $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(4-2)]; }, 290 => function ($stackPos) { - $this->semValue = new Stmt\TraitUseAdaptation\Alias($this->semStack[$stackPos-(4-1)][0], $this->semStack[$stackPos-(4-1)][1], null, $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 291 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)]); + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 292 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Node\Arg($this->semStack[$stackPos-(1-1)], false, false, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 293 => function ($stackPos) { - $this->semValue = array(null, $this->semStack[$stackPos-(1-1)]); + $this->semValue = new Node\Arg($this->semStack[$stackPos-(2-2)], true, false, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 294 => function ($stackPos) { - $this->semValue = null; + $this->semValue = new Node\Arg($this->semStack[$stackPos-(2-2)], false, true, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 295 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Node\Arg($this->semStack[$stackPos-(3-3)], false, false, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes, $this->semStack[$stackPos-(3-1)]); }, 296 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 297 => function ($stackPos) { - $this->semValue = 0; + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 298 => function ($stackPos) { - $this->semValue = 0; + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 299 => function ($stackPos) { $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 300 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 301 => function ($stackPos) { - $this->checkModifier($this->semStack[$stackPos-(2-1)], $this->semStack[$stackPos-(2-2)], $stackPos-(2-2)); $this->semValue = $this->semStack[$stackPos-(2-1)] | $this->semStack[$stackPos-(2-2)]; + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 302 => function ($stackPos) { - $this->semValue = Stmt\Class_::MODIFIER_PUBLIC; + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 303 => function ($stackPos) { - $this->semValue = Stmt\Class_::MODIFIER_PROTECTED; + $this->semValue = new Stmt\StaticVar($this->semStack[$stackPos-(1-1)], null, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 304 => function ($stackPos) { - $this->semValue = Stmt\Class_::MODIFIER_PRIVATE; + $this->semValue = new Stmt\StaticVar($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 305 => function ($stackPos) { - $this->semValue = Stmt\Class_::MODIFIER_STATIC; + if ($this->semStack[$stackPos-(2-2)] !== null) { $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; } }, 306 => function ($stackPos) { - $this->semValue = Stmt\Class_::MODIFIER_ABSTRACT; + $this->semValue = array(); }, 307 => function ($stackPos) { - $this->semValue = Stmt\Class_::MODIFIER_FINAL; + $startAttributes = $this->lookaheadStartAttributes; if (isset($startAttributes['comments'])) { $nop = new Stmt\Nop($this->createCommentNopAttributes($startAttributes['comments'])); } else { $nop = null; }; + if ($nop !== null) { $this->semStack[$stackPos-(1-1)][] = $nop; } $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 308 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = new Stmt\Property($this->semStack[$stackPos-(5-2)], $this->semStack[$stackPos-(5-4)], $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes, $this->semStack[$stackPos-(5-3)], $this->semStack[$stackPos-(5-1)]); + $this->checkProperty($this->semValue, $stackPos-(5-2)); }, 309 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semValue = new Stmt\ClassConst($this->semStack[$stackPos-(5-4)], $this->semStack[$stackPos-(5-2)], $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes, $this->semStack[$stackPos-(5-1)]); + $this->checkClassConst($this->semValue, $stackPos-(5-2)); }, 310 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = new Stmt\ClassMethod($this->semStack[$stackPos-(10-5)], ['type' => $this->semStack[$stackPos-(10-2)], 'byRef' => $this->semStack[$stackPos-(10-4)], 'params' => $this->semStack[$stackPos-(10-7)], 'returnType' => $this->semStack[$stackPos-(10-9)], 'stmts' => $this->semStack[$stackPos-(10-10)], 'attrGroups' => $this->semStack[$stackPos-(10-1)]], $this->startAttributeStack[$stackPos-(10-1)] + $this->endAttributes); + $this->checkClassMethod($this->semValue, $stackPos-(10-2)); }, 311 => function ($stackPos) { - $this->semValue = new Node\VarLikeIdentifier(substr($this->semStack[$stackPos-(1-1)], 1), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Stmt\TraitUse($this->semStack[$stackPos-(3-2)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 312 => function ($stackPos) { - $this->semValue = new Stmt\PropertyProperty($this->semStack[$stackPos-(1-1)], null, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = null; /* will be skipped */ }, 313 => function ($stackPos) { - $this->semValue = new Stmt\PropertyProperty($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = array(); }, 314 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = $this->semStack[$stackPos-(3-2)]; }, 315 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = array(); }, 316 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 317 => function ($stackPos) { - $this->semValue = array(); + $this->semValue = new Stmt\TraitUseAdaptation\Precedence($this->semStack[$stackPos-(4-1)][0], $this->semStack[$stackPos-(4-1)][1], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 318 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Stmt\TraitUseAdaptation\Alias($this->semStack[$stackPos-(5-1)][0], $this->semStack[$stackPos-(5-1)][1], $this->semStack[$stackPos-(5-3)], $this->semStack[$stackPos-(5-4)], $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes); }, 319 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Stmt\TraitUseAdaptation\Alias($this->semStack[$stackPos-(4-1)][0], $this->semStack[$stackPos-(4-1)][1], $this->semStack[$stackPos-(4-3)], null, $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 320 => function ($stackPos) { - $this->semValue = new Expr\Assign($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Stmt\TraitUseAdaptation\Alias($this->semStack[$stackPos-(4-1)][0], $this->semStack[$stackPos-(4-1)][1], null, $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 321 => function ($stackPos) { - $this->semValue = new Expr\Assign($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Stmt\TraitUseAdaptation\Alias($this->semStack[$stackPos-(4-1)][0], $this->semStack[$stackPos-(4-1)][1], null, $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 322 => function ($stackPos) { - $this->semValue = new Expr\Assign($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = array($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)]); }, 323 => function ($stackPos) { - $this->semValue = new Expr\AssignRef($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-4)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 324 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = array(null, $this->semStack[$stackPos-(1-1)]); }, 325 => function ($stackPos) { - $this->semValue = new Expr\Clone_($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = null; }, 326 => function ($stackPos) { - $this->semValue = new Expr\AssignOp\Plus($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 327 => function ($stackPos) { - $this->semValue = new Expr\AssignOp\Minus($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 328 => function ($stackPos) { - $this->semValue = new Expr\AssignOp\Mul($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = 0; }, 329 => function ($stackPos) { - $this->semValue = new Expr\AssignOp\Div($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = 0; }, 330 => function ($stackPos) { - $this->semValue = new Expr\AssignOp\Concat($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 331 => function ($stackPos) { - $this->semValue = new Expr\AssignOp\Mod($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 332 => function ($stackPos) { - $this->semValue = new Expr\AssignOp\BitwiseAnd($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->checkModifier($this->semStack[$stackPos-(2-1)], $this->semStack[$stackPos-(2-2)], $stackPos-(2-2)); $this->semValue = $this->semStack[$stackPos-(2-1)] | $this->semStack[$stackPos-(2-2)]; }, 333 => function ($stackPos) { - $this->semValue = new Expr\AssignOp\BitwiseOr($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = Stmt\Class_::MODIFIER_PUBLIC; }, 334 => function ($stackPos) { - $this->semValue = new Expr\AssignOp\BitwiseXor($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = Stmt\Class_::MODIFIER_PROTECTED; }, 335 => function ($stackPos) { - $this->semValue = new Expr\AssignOp\ShiftLeft($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = Stmt\Class_::MODIFIER_PRIVATE; }, 336 => function ($stackPos) { - $this->semValue = new Expr\AssignOp\ShiftRight($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = Stmt\Class_::MODIFIER_STATIC; }, 337 => function ($stackPos) { - $this->semValue = new Expr\AssignOp\Pow($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = Stmt\Class_::MODIFIER_ABSTRACT; }, 338 => function ($stackPos) { - $this->semValue = new Expr\AssignOp\Coalesce($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = Stmt\Class_::MODIFIER_FINAL; }, 339 => function ($stackPos) { - $this->semValue = new Expr\PostInc($this->semStack[$stackPos-(2-1)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 340 => function ($stackPos) { - $this->semValue = new Expr\PreInc($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 341 => function ($stackPos) { - $this->semValue = new Expr\PostDec($this->semStack[$stackPos-(2-1)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 342 => function ($stackPos) { - $this->semValue = new Expr\PreDec($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Node\VarLikeIdentifier(substr($this->semStack[$stackPos-(1-1)], 1), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 343 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\BooleanOr($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Stmt\PropertyProperty($this->semStack[$stackPos-(1-1)], null, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 344 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\BooleanAnd($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Stmt\PropertyProperty($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 345 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\LogicalOr($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 346 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\LogicalAnd($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 347 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\LogicalXor($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 348 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\BitwiseOr($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 349 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\BitwiseAnd($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = array(); }, 350 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\BitwiseXor($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 351 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Concat($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 352 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Plus($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\Assign($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 353 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Minus($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\Assign($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 354 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Mul($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\Assign($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 355 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Div($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\AssignRef($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-4)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 356 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Mod($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 357 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\ShiftLeft($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 358 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\ShiftRight($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\Clone_($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 359 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Pow($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\AssignOp\Plus($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 360 => function ($stackPos) { - $this->semValue = new Expr\UnaryPlus($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\AssignOp\Minus($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 361 => function ($stackPos) { - $this->semValue = new Expr\UnaryMinus($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\AssignOp\Mul($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 362 => function ($stackPos) { - $this->semValue = new Expr\BooleanNot($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\AssignOp\Div($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 363 => function ($stackPos) { - $this->semValue = new Expr\BitwiseNot($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\AssignOp\Concat($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 364 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Identical($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\AssignOp\Mod($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 365 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\NotIdentical($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\AssignOp\BitwiseAnd($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 366 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Equal($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\AssignOp\BitwiseOr($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 367 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\NotEqual($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\AssignOp\BitwiseXor($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 368 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Spaceship($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\AssignOp\ShiftLeft($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 369 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Smaller($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\AssignOp\ShiftRight($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 370 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\SmallerOrEqual($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\AssignOp\Pow($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 371 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Greater($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\AssignOp\Coalesce($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 372 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\GreaterOrEqual($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\PostInc($this->semStack[$stackPos-(2-1)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 373 => function ($stackPos) { - $this->semValue = new Expr\Instanceof_($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\PreInc($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 374 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(3-2)]; + $this->semValue = new Expr\PostDec($this->semStack[$stackPos-(2-1)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 375 => function ($stackPos) { - $this->semValue = new Expr\Ternary($this->semStack[$stackPos-(5-1)], $this->semStack[$stackPos-(5-3)], $this->semStack[$stackPos-(5-5)], $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes); + $this->semValue = new Expr\PreDec($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 376 => function ($stackPos) { - $this->semValue = new Expr\Ternary($this->semStack[$stackPos-(4-1)], null, $this->semStack[$stackPos-(4-4)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\BooleanOr($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 377 => function ($stackPos) { - $this->semValue = new Expr\BinaryOp\Coalesce($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\BooleanAnd($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 378 => function ($stackPos) { - $this->semValue = new Expr\Isset_($this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\LogicalOr($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 379 => function ($stackPos) { - $this->semValue = new Expr\Empty_($this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\LogicalAnd($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 380 => function ($stackPos) { - $this->semValue = new Expr\Include_($this->semStack[$stackPos-(2-2)], Expr\Include_::TYPE_INCLUDE, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\LogicalXor($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 381 => function ($stackPos) { - $this->semValue = new Expr\Include_($this->semStack[$stackPos-(2-2)], Expr\Include_::TYPE_INCLUDE_ONCE, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\BitwiseOr($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 382 => function ($stackPos) { - $this->semValue = new Expr\Eval_($this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\BitwiseAnd($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 383 => function ($stackPos) { - $this->semValue = new Expr\Include_($this->semStack[$stackPos-(2-2)], Expr\Include_::TYPE_REQUIRE, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\BitwiseXor($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 384 => function ($stackPos) { - $this->semValue = new Expr\Include_($this->semStack[$stackPos-(2-2)], Expr\Include_::TYPE_REQUIRE_ONCE, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Concat($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 385 => function ($stackPos) { - $this->semValue = new Expr\Cast\Int_($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Plus($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 386 => function ($stackPos) { - $attrs = $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes; - $attrs['kind'] = $this->getFloatCastKind($this->semStack[$stackPos-(2-1)]); - $this->semValue = new Expr\Cast\Double($this->semStack[$stackPos-(2-2)], $attrs); + $this->semValue = new Expr\BinaryOp\Minus($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 387 => function ($stackPos) { - $this->semValue = new Expr\Cast\String_($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Mul($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 388 => function ($stackPos) { - $this->semValue = new Expr\Cast\Array_($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Div($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 389 => function ($stackPos) { - $this->semValue = new Expr\Cast\Object_($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Mod($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 390 => function ($stackPos) { - $this->semValue = new Expr\Cast\Bool_($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\ShiftLeft($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 391 => function ($stackPos) { - $this->semValue = new Expr\Cast\Unset_($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\ShiftRight($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 392 => function ($stackPos) { - $attrs = $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes; - $attrs['kind'] = strtolower($this->semStack[$stackPos-(2-1)]) === 'exit' ? Expr\Exit_::KIND_EXIT : Expr\Exit_::KIND_DIE; - $this->semValue = new Expr\Exit_($this->semStack[$stackPos-(2-2)], $attrs); + $this->semValue = new Expr\BinaryOp\Pow($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 393 => function ($stackPos) { - $this->semValue = new Expr\ErrorSuppress($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\UnaryPlus($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 394 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\UnaryMinus($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 395 => function ($stackPos) { - $this->semValue = new Expr\ShellExec($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\BooleanNot($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 396 => function ($stackPos) { - $this->semValue = new Expr\Print_($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\BitwiseNot($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 397 => function ($stackPos) { - $this->semValue = new Expr\Yield_(null, null, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Identical($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 398 => function ($stackPos) { - $this->semValue = new Expr\Yield_($this->semStack[$stackPos-(2-2)], null, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\NotIdentical($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 399 => function ($stackPos) { - $this->semValue = new Expr\Yield_($this->semStack[$stackPos-(4-4)], $this->semStack[$stackPos-(4-2)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Equal($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 400 => function ($stackPos) { - $this->semValue = new Expr\YieldFrom($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\NotEqual($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 401 => function ($stackPos) { - $this->semValue = new Expr\ArrowFunction(['static' => false, 'byRef' => $this->semStack[$stackPos-(8-2)], 'params' => $this->semStack[$stackPos-(8-4)], 'returnType' => $this->semStack[$stackPos-(8-6)], 'expr' => $this->semStack[$stackPos-(8-8)]], $this->startAttributeStack[$stackPos-(8-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Spaceship($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 402 => function ($stackPos) { - $this->semValue = new Expr\ArrowFunction(['static' => true, 'byRef' => $this->semStack[$stackPos-(9-3)], 'params' => $this->semStack[$stackPos-(9-5)], 'returnType' => $this->semStack[$stackPos-(9-7)], 'expr' => $this->semStack[$stackPos-(9-9)]], $this->startAttributeStack[$stackPos-(9-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Smaller($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 403 => function ($stackPos) { - $this->semValue = new Expr\Closure(['static' => false, 'byRef' => $this->semStack[$stackPos-(8-2)], 'params' => $this->semStack[$stackPos-(8-4)], 'uses' => $this->semStack[$stackPos-(8-6)], 'returnType' => $this->semStack[$stackPos-(8-7)], 'stmts' => $this->semStack[$stackPos-(8-8)]], $this->startAttributeStack[$stackPos-(8-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\SmallerOrEqual($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 404 => function ($stackPos) { - $this->semValue = new Expr\Closure(['static' => true, 'byRef' => $this->semStack[$stackPos-(9-3)], 'params' => $this->semStack[$stackPos-(9-5)], 'uses' => $this->semStack[$stackPos-(9-7)], 'returnType' => $this->semStack[$stackPos-(9-8)], 'stmts' => $this->semStack[$stackPos-(9-9)]], $this->startAttributeStack[$stackPos-(9-1)] + $this->endAttributes); + $this->semValue = new Expr\BinaryOp\Greater($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 405 => function ($stackPos) { - $this->semValue = array(new Stmt\Class_(null, ['type' => 0, 'extends' => $this->semStack[$stackPos-(7-3)], 'implements' => $this->semStack[$stackPos-(7-4)], 'stmts' => $this->semStack[$stackPos-(7-6)]], $this->startAttributeStack[$stackPos-(7-1)] + $this->endAttributes), $this->semStack[$stackPos-(7-2)]); - $this->checkClass($this->semValue[0], -1); + $this->semValue = new Expr\BinaryOp\GreaterOrEqual($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 406 => function ($stackPos) { - $this->semValue = new Expr\New_($this->semStack[$stackPos-(3-2)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\Instanceof_($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 407 => function ($stackPos) { - list($class, $ctorArgs) = $this->semStack[$stackPos-(2-2)]; $this->semValue = new Expr\New_($class, $ctorArgs, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(3-2)]; }, 408 => function ($stackPos) { - $this->semValue = array(); + $this->semValue = new Expr\Ternary($this->semStack[$stackPos-(5-1)], $this->semStack[$stackPos-(5-3)], $this->semStack[$stackPos-(5-5)], $this->startAttributeStack[$stackPos-(5-1)] + $this->endAttributes); }, 409 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(4-3)]; + $this->semValue = new Expr\Ternary($this->semStack[$stackPos-(4-1)], null, $this->semStack[$stackPos-(4-4)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 410 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = new Expr\BinaryOp\Coalesce($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 411 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semValue = new Expr\Isset_($this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 412 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = new Expr\Empty_($this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 413 => function ($stackPos) { - $this->semValue = new Expr\ClosureUse($this->semStack[$stackPos-(2-2)], $this->semStack[$stackPos-(2-1)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\Include_($this->semStack[$stackPos-(2-2)], Expr\Include_::TYPE_INCLUDE, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 414 => function ($stackPos) { - $this->semValue = new Expr\FuncCall($this->semStack[$stackPos-(2-1)], $this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\Include_($this->semStack[$stackPos-(2-2)], Expr\Include_::TYPE_INCLUDE_ONCE, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 415 => function ($stackPos) { - $this->semValue = new Expr\FuncCall($this->semStack[$stackPos-(2-1)], $this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\Eval_($this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 416 => function ($stackPos) { - $this->semValue = new Expr\StaticCall($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->semStack[$stackPos-(4-4)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = new Expr\Include_($this->semStack[$stackPos-(2-2)], Expr\Include_::TYPE_REQUIRE, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 417 => function ($stackPos) { - $this->semValue = new Name($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Expr\Include_($this->semStack[$stackPos-(2-2)], Expr\Include_::TYPE_REQUIRE_ONCE, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 418 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\Cast\Int_($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 419 => function ($stackPos) { - $this->semValue = new Name($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $attrs = $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes; + $attrs['kind'] = $this->getFloatCastKind($this->semStack[$stackPos-(2-1)]); + $this->semValue = new Expr\Cast\Double($this->semStack[$stackPos-(2-2)], $attrs); }, 420 => function ($stackPos) { - $this->semValue = new Name\FullyQualified($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\Cast\String_($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 421 => function ($stackPos) { - $this->semValue = new Name\Relative($this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\Cast\Array_($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 422 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\Cast\Object_($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 423 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\Cast\Bool_($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 424 => function ($stackPos) { - $this->semValue = new Expr\Error($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); $this->errorState = 2; + $this->semValue = new Expr\Cast\Unset_($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 425 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $attrs = $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes; + $attrs['kind'] = strtolower($this->semStack[$stackPos-(2-1)]) === 'exit' ? Expr\Exit_::KIND_EXIT : Expr\Exit_::KIND_DIE; + $this->semValue = new Expr\Exit_($this->semStack[$stackPos-(2-2)], $attrs); }, 426 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\ErrorSuppress($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 427 => function ($stackPos) { - $this->semValue = null; + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 428 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(3-2)]; + $this->semValue = new Expr\ShellExec($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 429 => function ($stackPos) { - $this->semValue = array(); + $this->semValue = new Expr\Print_($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 430 => function ($stackPos) { - $this->semValue = array(new Scalar\EncapsedStringPart(Scalar\String_::parseEscapeSequences($this->semStack[$stackPos-(1-1)], '`'), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes)); + $this->semValue = new Expr\Yield_(null, null, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 431 => function ($stackPos) { - foreach ($this->semStack[$stackPos-(1-1)] as $s) { if ($s instanceof Node\Scalar\EncapsedStringPart) { $s->value = Node\Scalar\String_::parseEscapeSequences($s->value, '`', true); } }; $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\Yield_($this->semStack[$stackPos-(2-2)], null, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 432 => function ($stackPos) { - $this->semValue = array(); + $this->semValue = new Expr\Yield_($this->semStack[$stackPos-(4-4)], $this->semStack[$stackPos-(4-2)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 433 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\YieldFrom($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 434 => function ($stackPos) { - $this->semValue = new Expr\ConstFetch($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Expr\Throw_($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 435 => function ($stackPos) { - $this->semValue = new Expr\ClassConstFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\ArrowFunction(['static' => false, 'byRef' => $this->semStack[$stackPos-(8-2)], 'params' => $this->semStack[$stackPos-(8-4)], 'returnType' => $this->semStack[$stackPos-(8-6)], 'expr' => $this->semStack[$stackPos-(8-8)], 'attrGroups' => []], $this->startAttributeStack[$stackPos-(8-1)] + $this->endAttributes); }, 436 => function ($stackPos) { - $this->semValue = new Expr\ClassConstFetch($this->semStack[$stackPos-(3-1)], new Expr\Error($this->startAttributeStack[$stackPos-(3-3)] + $this->endAttributeStack[$stackPos-(3-3)]), $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); $this->errorState = 2; + $this->semValue = new Expr\ArrowFunction(['static' => true, 'byRef' => $this->semStack[$stackPos-(9-3)], 'params' => $this->semStack[$stackPos-(9-5)], 'returnType' => $this->semStack[$stackPos-(9-7)], 'expr' => $this->semStack[$stackPos-(9-9)], 'attrGroups' => []], $this->startAttributeStack[$stackPos-(9-1)] + $this->endAttributes); }, 437 => function ($stackPos) { - $attrs = $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes; $attrs['kind'] = Expr\Array_::KIND_SHORT; - $this->semValue = new Expr\Array_($this->semStack[$stackPos-(3-2)], $attrs); + $this->semValue = new Expr\Closure(['static' => false, 'byRef' => $this->semStack[$stackPos-(8-2)], 'params' => $this->semStack[$stackPos-(8-4)], 'uses' => $this->semStack[$stackPos-(8-6)], 'returnType' => $this->semStack[$stackPos-(8-7)], 'stmts' => $this->semStack[$stackPos-(8-8)], 'attrGroups' => []], $this->startAttributeStack[$stackPos-(8-1)] + $this->endAttributes); }, 438 => function ($stackPos) { - $attrs = $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes; $attrs['kind'] = Expr\Array_::KIND_LONG; - $this->semValue = new Expr\Array_($this->semStack[$stackPos-(4-3)], $attrs); + $this->semValue = new Expr\Closure(['static' => true, 'byRef' => $this->semStack[$stackPos-(9-3)], 'params' => $this->semStack[$stackPos-(9-5)], 'uses' => $this->semStack[$stackPos-(9-7)], 'returnType' => $this->semStack[$stackPos-(9-8)], 'stmts' => $this->semStack[$stackPos-(9-9)], 'attrGroups' => []], $this->startAttributeStack[$stackPos-(9-1)] + $this->endAttributes); }, 439 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\ArrowFunction(['static' => false, 'byRef' => $this->semStack[$stackPos-(9-3)], 'params' => $this->semStack[$stackPos-(9-5)], 'returnType' => $this->semStack[$stackPos-(9-7)], 'expr' => $this->semStack[$stackPos-(9-9)], 'attrGroups' => $this->semStack[$stackPos-(9-1)]], $this->startAttributeStack[$stackPos-(9-1)] + $this->endAttributes); }, 440 => function ($stackPos) { - $attrs = $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes; $attrs['kind'] = ($this->semStack[$stackPos-(1-1)][0] === "'" || ($this->semStack[$stackPos-(1-1)][1] === "'" && ($this->semStack[$stackPos-(1-1)][0] === 'b' || $this->semStack[$stackPos-(1-1)][0] === 'B')) ? Scalar\String_::KIND_SINGLE_QUOTED : Scalar\String_::KIND_DOUBLE_QUOTED); - $this->semValue = new Scalar\String_(Scalar\String_::parse($this->semStack[$stackPos-(1-1)]), $attrs); + $this->semValue = new Expr\ArrowFunction(['static' => true, 'byRef' => $this->semStack[$stackPos-(10-4)], 'params' => $this->semStack[$stackPos-(10-6)], 'returnType' => $this->semStack[$stackPos-(10-8)], 'expr' => $this->semStack[$stackPos-(10-10)], 'attrGroups' => $this->semStack[$stackPos-(10-1)]], $this->startAttributeStack[$stackPos-(10-1)] + $this->endAttributes); }, 441 => function ($stackPos) { - $this->semValue = $this->parseLNumber($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Expr\Closure(['static' => false, 'byRef' => $this->semStack[$stackPos-(9-3)], 'params' => $this->semStack[$stackPos-(9-5)], 'uses' => $this->semStack[$stackPos-(9-7)], 'returnType' => $this->semStack[$stackPos-(9-8)], 'stmts' => $this->semStack[$stackPos-(9-9)], 'attrGroups' => $this->semStack[$stackPos-(9-1)]], $this->startAttributeStack[$stackPos-(9-1)] + $this->endAttributes); }, 442 => function ($stackPos) { - $this->semValue = new Scalar\DNumber(Scalar\DNumber::parse($this->semStack[$stackPos-(1-1)]), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Expr\Closure(['static' => true, 'byRef' => $this->semStack[$stackPos-(10-4)], 'params' => $this->semStack[$stackPos-(10-6)], 'uses' => $this->semStack[$stackPos-(10-8)], 'returnType' => $this->semStack[$stackPos-(10-9)], 'stmts' => $this->semStack[$stackPos-(10-10)], 'attrGroups' => $this->semStack[$stackPos-(10-1)]], $this->startAttributeStack[$stackPos-(10-1)] + $this->endAttributes); }, 443 => function ($stackPos) { - $this->semValue = new Scalar\MagicConst\Line($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = array(new Stmt\Class_(null, ['type' => 0, 'extends' => $this->semStack[$stackPos-(8-4)], 'implements' => $this->semStack[$stackPos-(8-5)], 'stmts' => $this->semStack[$stackPos-(8-7)], 'attrGroups' => $this->semStack[$stackPos-(8-1)]], $this->startAttributeStack[$stackPos-(8-1)] + $this->endAttributes), $this->semStack[$stackPos-(8-3)]); + $this->checkClass($this->semValue[0], -1); }, 444 => function ($stackPos) { - $this->semValue = new Scalar\MagicConst\File($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Expr\New_($this->semStack[$stackPos-(3-2)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 445 => function ($stackPos) { - $this->semValue = new Scalar\MagicConst\Dir($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + list($class, $ctorArgs) = $this->semStack[$stackPos-(2-2)]; $this->semValue = new Expr\New_($class, $ctorArgs, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 446 => function ($stackPos) { - $this->semValue = new Scalar\MagicConst\Class_($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = array(); }, 447 => function ($stackPos) { - $this->semValue = new Scalar\MagicConst\Trait_($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(4-3)]; }, 448 => function ($stackPos) { - $this->semValue = new Scalar\MagicConst\Method($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(2-1)]; }, 449 => function ($stackPos) { - $this->semValue = new Scalar\MagicConst\Function_($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = array($this->semStack[$stackPos-(1-1)]); }, 450 => function ($stackPos) { - $this->semValue = new Scalar\MagicConst\Namespace_($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; }, 451 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\ClosureUse($this->semStack[$stackPos-(2-2)], $this->semStack[$stackPos-(2-1)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 452 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\FuncCall($this->semStack[$stackPos-(2-1)], $this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 453 => function ($stackPos) { - $this->semValue = $this->parseDocString($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-2)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes, $this->startAttributeStack[$stackPos-(3-3)] + $this->endAttributeStack[$stackPos-(3-3)], true); + $this->semValue = new Expr\FuncCall($this->semStack[$stackPos-(2-1)], $this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 454 => function ($stackPos) { - $this->semValue = $this->parseDocString($this->semStack[$stackPos-(2-1)], '', $this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes, $this->startAttributeStack[$stackPos-(2-2)] + $this->endAttributeStack[$stackPos-(2-2)], true); + $this->semValue = new Expr\StaticCall($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->semStack[$stackPos-(4-4)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 455 => function ($stackPos) { - $attrs = $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes; $attrs['kind'] = Scalar\String_::KIND_DOUBLE_QUOTED; - foreach ($this->semStack[$stackPos-(3-2)] as $s) { if ($s instanceof Node\Scalar\EncapsedStringPart) { $s->value = Node\Scalar\String_::parseEscapeSequences($s->value, '"', true); } }; $this->semValue = new Scalar\Encapsed($this->semStack[$stackPos-(3-2)], $attrs); + $this->semValue = new Name($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 456 => function ($stackPos) { - $this->semValue = $this->parseDocString($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-2)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes, $this->startAttributeStack[$stackPos-(3-3)] + $this->endAttributeStack[$stackPos-(3-3)], true); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 457 => function ($stackPos) { - $this->semValue = null; + $this->semValue = new Name($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 458 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Name($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 459 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Name\FullyQualified(substr($this->semStack[$stackPos-(1-1)], 1), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 460 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(3-2)]; + $this->semValue = new Name\Relative(substr($this->semStack[$stackPos-(1-1)], 10), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 461 => function ($stackPos) { $this->semValue = $this->semStack[$stackPos-(1-1)]; @@ -2286,204 +2383,334 @@ protected function initReduceCallbacks() { $this->semValue = $this->semStack[$stackPos-(3-2)]; }, 464 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\Error($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); $this->errorState = 2; }, 465 => function ($stackPos) { - $this->semValue = new Expr\Variable($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 466 => function ($stackPos) { - $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 467 => function ($stackPos) { - $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = null; }, 468 => function ($stackPos) { - $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(3-2)]; }, 469 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = array(); }, 470 => function ($stackPos) { - $this->semValue = new Expr\MethodCall($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->semStack[$stackPos-(4-4)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = array(new Scalar\EncapsedStringPart(Scalar\String_::parseEscapeSequences($this->semStack[$stackPos-(1-1)], '`'), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes)); }, 471 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + foreach ($this->semStack[$stackPos-(1-1)] as $s) { if ($s instanceof Node\Scalar\EncapsedStringPart) { $s->value = Node\Scalar\String_::parseEscapeSequences($s->value, '`', true); } }; $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 472 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = array(); }, 473 => function ($stackPos) { - $this->semValue = new Expr\PropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 474 => function ($stackPos) { - $this->semValue = substr($this->semStack[$stackPos-(1-1)], 1); + $this->semValue = new Expr\ConstFetch($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 475 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(4-3)]; + $this->semValue = new Scalar\MagicConst\Line($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 476 => function ($stackPos) { - $this->semValue = new Expr\Variable($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Scalar\MagicConst\File($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 477 => function ($stackPos) { - $this->semValue = new Expr\Error($this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); $this->errorState = 2; + $this->semValue = new Scalar\MagicConst\Dir($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 478 => function ($stackPos) { - $var = $this->semStack[$stackPos-(1-1)]; $this->semValue = \is_string($var) ? new Node\VarLikeIdentifier($var, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes) : $var; + $this->semValue = new Scalar\MagicConst\Class_($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 479 => function ($stackPos) { - $this->semValue = new Expr\StaticPropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Scalar\MagicConst\Trait_($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 480 => function ($stackPos) { - $this->semValue = new Expr\Variable($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Scalar\MagicConst\Method($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 481 => function ($stackPos) { - $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = new Scalar\MagicConst\Function_($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 482 => function ($stackPos) { - $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = new Scalar\MagicConst\Namespace_($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 483 => function ($stackPos) { - $this->semValue = new Expr\PropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\ClassConstFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 484 => function ($stackPos) { - $this->semValue = new Expr\StaticPropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\ClassConstFetch($this->semStack[$stackPos-(3-1)], new Expr\Error($this->startAttributeStack[$stackPos-(3-3)] + $this->endAttributeStack[$stackPos-(3-3)]), $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); $this->errorState = 2; }, 485 => function ($stackPos) { - $this->semValue = new Expr\StaticPropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $attrs = $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes; $attrs['kind'] = Expr\Array_::KIND_SHORT; + $this->semValue = new Expr\Array_($this->semStack[$stackPos-(3-2)], $attrs); }, 486 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $attrs = $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes; $attrs['kind'] = Expr\Array_::KIND_LONG; + $this->semValue = new Expr\Array_($this->semStack[$stackPos-(4-3)], $attrs); }, 487 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(3-2)]; + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 488 => function ($stackPos) { - $this->semValue = new Expr\Variable($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $attrs = $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes; $attrs['kind'] = ($this->semStack[$stackPos-(1-1)][0] === "'" || ($this->semStack[$stackPos-(1-1)][1] === "'" && ($this->semStack[$stackPos-(1-1)][0] === 'b' || $this->semStack[$stackPos-(1-1)][0] === 'B')) ? Scalar\String_::KIND_SINGLE_QUOTED : Scalar\String_::KIND_DOUBLE_QUOTED); + $this->semValue = new Scalar\String_(Scalar\String_::parse($this->semStack[$stackPos-(1-1)]), $attrs); }, 489 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $attrs = $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes; $attrs['kind'] = Scalar\String_::KIND_DOUBLE_QUOTED; + foreach ($this->semStack[$stackPos-(3-2)] as $s) { if ($s instanceof Node\Scalar\EncapsedStringPart) { $s->value = Node\Scalar\String_::parseEscapeSequences($s->value, '"', true); } }; $this->semValue = new Scalar\Encapsed($this->semStack[$stackPos-(3-2)], $attrs); }, 490 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(3-2)]; + $this->semValue = $this->parseLNumber($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 491 => function ($stackPos) { - $this->semValue = new Expr\Variable($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Scalar\DNumber(Scalar\DNumber::parse($this->semStack[$stackPos-(1-1)]), $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); }, 492 => function ($stackPos) { - $this->semValue = new Expr\Error($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); $this->errorState = 2; + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 493 => function ($stackPos) { - $this->semValue = new Expr\List_($this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 494 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 495 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semValue = $this->parseDocString($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-2)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes, $this->startAttributeStack[$stackPos-(3-3)] + $this->endAttributeStack[$stackPos-(3-3)], true); }, 496 => function ($stackPos) { - $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(1-1)], null, false, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = $this->parseDocString($this->semStack[$stackPos-(2-1)], '', $this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes, $this->startAttributeStack[$stackPos-(2-2)] + $this->endAttributeStack[$stackPos-(2-2)], true); }, 497 => function ($stackPos) { - $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(2-2)], null, true, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = $this->parseDocString($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-2)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes, $this->startAttributeStack[$stackPos-(3-3)] + $this->endAttributeStack[$stackPos-(3-3)], true); }, 498 => function ($stackPos) { - $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(1-1)], null, false, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = null; }, 499 => function ($stackPos) { - $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(3-3)], $this->semStack[$stackPos-(3-1)], false, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 500 => function ($stackPos) { - $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(4-4)], $this->semStack[$stackPos-(4-1)], true, $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 501 => function ($stackPos) { - $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(3-3)], $this->semStack[$stackPos-(3-1)], false, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(3-2)]; }, 502 => function ($stackPos) { - $this->semValue = null; + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 503 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; $end = count($this->semValue)-1; if ($this->semValue[$end] === null) array_pop($this->semValue); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 504 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos]; + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 505 => function ($stackPos) { - /* do nothing -- prevent default action of $$=$this->semStack[$1]. See $551. */ + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 506 => function ($stackPos) { - $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 507 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semValue = $this->semStack[$stackPos-(3-2)]; }, 508 => function ($stackPos) { - $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(3-3)], $this->semStack[$stackPos-(3-1)], false, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 509 => function ($stackPos) { - $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(1-1)], null, false, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 510 => function ($stackPos) { - $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(4-4)], $this->semStack[$stackPos-(4-1)], true, $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 511 => function ($stackPos) { - $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(2-2)], null, true, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 512 => function ($stackPos) { - $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(2-2)], null, false, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes, true, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 513 => function ($stackPos) { - $this->semValue = null; + $this->semValue = new Expr\MethodCall($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->semStack[$stackPos-(4-4)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 514 => function ($stackPos) { - $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = new Expr\NullsafeMethodCall($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->semStack[$stackPos-(4-4)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 515 => function ($stackPos) { - $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; + $this->semValue = null; }, 516 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(1-1)]); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 517 => function ($stackPos) { - $this->semValue = array($this->semStack[$stackPos-(2-1)], $this->semStack[$stackPos-(2-2)]); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 518 => function ($stackPos) { - $this->semValue = new Scalar\EncapsedStringPart($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 519 => function ($stackPos) { - $this->semValue = new Expr\Variable($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Expr\PropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 520 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(1-1)]; + $this->semValue = new Expr\NullsafePropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 521 => function ($stackPos) { - $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 522 => function ($stackPos) { - $this->semValue = new Expr\PropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\Variable($this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 523 => function ($stackPos) { - $this->semValue = new Expr\Variable($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\Variable($this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); }, 524 => function ($stackPos) { - $this->semValue = new Expr\Variable($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + $this->semValue = new Expr\Variable(new Expr\Error($this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes), $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); $this->errorState = 2; }, 525 => function ($stackPos) { - $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(6-2)], $this->semStack[$stackPos-(6-4)], $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); + $var = $this->semStack[$stackPos-(1-1)]->name; $this->semValue = \is_string($var) ? new Node\VarLikeIdentifier($var, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes) : $var; }, 526 => function ($stackPos) { - $this->semValue = $this->semStack[$stackPos-(3-2)]; + $this->semValue = new Expr\StaticPropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); }, 527 => function ($stackPos) { - $this->semValue = new Scalar\String_($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = $this->semStack[$stackPos-(1-1)]; }, 528 => function ($stackPos) { - $this->semValue = $this->parseNumString($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 529 => function ($stackPos) { - $this->semValue = $this->parseNumString('-' . $this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); }, 530 => function ($stackPos) { + $this->semValue = new Expr\PropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + }, + 531 => function ($stackPos) { + $this->semValue = new Expr\NullsafePropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + }, + 532 => function ($stackPos) { + $this->semValue = new Expr\StaticPropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + }, + 533 => function ($stackPos) { + $this->semValue = new Expr\StaticPropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + }, + 534 => function ($stackPos) { + $this->semValue = $this->semStack[$stackPos-(1-1)]; + }, + 535 => function ($stackPos) { + $this->semValue = $this->semStack[$stackPos-(3-2)]; + }, + 536 => function ($stackPos) { + $this->semValue = $this->semStack[$stackPos-(1-1)]; + }, + 537 => function ($stackPos) { + $this->semValue = $this->semStack[$stackPos-(1-1)]; + }, + 538 => function ($stackPos) { + $this->semValue = $this->semStack[$stackPos-(3-2)]; + }, + 539 => function ($stackPos) { + $this->semValue = $this->semStack[$stackPos-(1-1)]; + }, + 540 => function ($stackPos) { + $this->semValue = new Expr\Error($this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); $this->errorState = 2; + }, + 541 => function ($stackPos) { + $this->semValue = new Expr\List_($this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + }, + 542 => function ($stackPos) { + $this->semValue = $this->semStack[$stackPos-(1-1)]; $end = count($this->semValue)-1; if ($this->semValue[$end] === null) array_pop($this->semValue); + }, + 543 => function ($stackPos) { + $this->semValue = $this->semStack[$stackPos]; + }, + 544 => function ($stackPos) { + /* do nothing -- prevent default action of $$=$this->semStack[$1]. See $551. */ + }, + 545 => function ($stackPos) { + $this->semStack[$stackPos-(3-1)][] = $this->semStack[$stackPos-(3-3)]; $this->semValue = $this->semStack[$stackPos-(3-1)]; + }, + 546 => function ($stackPos) { + $this->semValue = array($this->semStack[$stackPos-(1-1)]); + }, + 547 => function ($stackPos) { + $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(1-1)], null, false, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + }, + 548 => function ($stackPos) { + $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(2-2)], null, true, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + }, + 549 => function ($stackPos) { + $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(1-1)], null, false, $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + }, + 550 => function ($stackPos) { + $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(3-3)], $this->semStack[$stackPos-(3-1)], false, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + }, + 551 => function ($stackPos) { + $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(4-4)], $this->semStack[$stackPos-(4-1)], true, $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + }, + 552 => function ($stackPos) { + $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(3-3)], $this->semStack[$stackPos-(3-1)], false, $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + }, + 553 => function ($stackPos) { + $this->semValue = new Expr\ArrayItem($this->semStack[$stackPos-(2-2)], null, false, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes, true, $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + }, + 554 => function ($stackPos) { + $this->semValue = null; + }, + 555 => function ($stackPos) { + $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; + }, + 556 => function ($stackPos) { + $this->semStack[$stackPos-(2-1)][] = $this->semStack[$stackPos-(2-2)]; $this->semValue = $this->semStack[$stackPos-(2-1)]; + }, + 557 => function ($stackPos) { + $this->semValue = array($this->semStack[$stackPos-(1-1)]); + }, + 558 => function ($stackPos) { + $this->semValue = array($this->semStack[$stackPos-(2-1)], $this->semStack[$stackPos-(2-2)]); + }, + 559 => function ($stackPos) { + $this->semValue = new Scalar\EncapsedStringPart($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + }, + 560 => function ($stackPos) { + $this->semValue = new Expr\Variable($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + }, + 561 => function ($stackPos) { + $this->semValue = $this->semStack[$stackPos-(1-1)]; + }, + 562 => function ($stackPos) { + $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(4-1)], $this->semStack[$stackPos-(4-3)], $this->startAttributeStack[$stackPos-(4-1)] + $this->endAttributes); + }, + 563 => function ($stackPos) { + $this->semValue = new Expr\PropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + }, + 564 => function ($stackPos) { + $this->semValue = new Expr\NullsafePropertyFetch($this->semStack[$stackPos-(3-1)], $this->semStack[$stackPos-(3-3)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + }, + 565 => function ($stackPos) { + $this->semValue = new Expr\Variable($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + }, + 566 => function ($stackPos) { + $this->semValue = new Expr\Variable($this->semStack[$stackPos-(3-2)], $this->startAttributeStack[$stackPos-(3-1)] + $this->endAttributes); + }, + 567 => function ($stackPos) { + $this->semValue = new Expr\ArrayDimFetch($this->semStack[$stackPos-(6-2)], $this->semStack[$stackPos-(6-4)], $this->startAttributeStack[$stackPos-(6-1)] + $this->endAttributes); + }, + 568 => function ($stackPos) { + $this->semValue = $this->semStack[$stackPos-(3-2)]; + }, + 569 => function ($stackPos) { + $this->semValue = new Scalar\String_($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + }, + 570 => function ($stackPos) { + $this->semValue = $this->parseNumString($this->semStack[$stackPos-(1-1)], $this->startAttributeStack[$stackPos-(1-1)] + $this->endAttributes); + }, + 571 => function ($stackPos) { + $this->semValue = $this->parseNumString('-' . $this->semStack[$stackPos-(2-2)], $this->startAttributeStack[$stackPos-(2-1)] + $this->endAttributes); + }, + 572 => function ($stackPos) { $this->semValue = $this->semStack[$stackPos-(1-1)]; }, ]; diff --git a/nikic/php-parser/lib/PhpParser/Parser/Tokens.php b/nikic/php-parser/lib/PhpParser/Parser/Tokens.php index 50c5bf574..ed2062b46 100644 --- a/nikic/php-parser/lib/PhpParser/Parser/Tokens.php +++ b/nikic/php-parser/lib/PhpParser/Parser/Tokens.php @@ -6,84 +6,84 @@ final class Tokens { const YYERRTOK = 256; - const T_INCLUDE = 257; - const T_INCLUDE_ONCE = 258; - const T_EVAL = 259; - const T_REQUIRE = 260; - const T_REQUIRE_ONCE = 261; - const T_LOGICAL_OR = 262; - const T_LOGICAL_XOR = 263; - const T_LOGICAL_AND = 264; - const T_PRINT = 265; - const T_YIELD = 266; - const T_DOUBLE_ARROW = 267; - const T_YIELD_FROM = 268; - const T_PLUS_EQUAL = 269; - const T_MINUS_EQUAL = 270; - const T_MUL_EQUAL = 271; - const T_DIV_EQUAL = 272; - const T_CONCAT_EQUAL = 273; - const T_MOD_EQUAL = 274; - const T_AND_EQUAL = 275; - const T_OR_EQUAL = 276; - const T_XOR_EQUAL = 277; - const T_SL_EQUAL = 278; - const T_SR_EQUAL = 279; - const T_POW_EQUAL = 280; - const T_COALESCE_EQUAL = 281; - const T_COALESCE = 282; - const T_BOOLEAN_OR = 283; - const T_BOOLEAN_AND = 284; - const T_IS_EQUAL = 285; - const T_IS_NOT_EQUAL = 286; - const T_IS_IDENTICAL = 287; - const T_IS_NOT_IDENTICAL = 288; - const T_SPACESHIP = 289; - const T_IS_SMALLER_OR_EQUAL = 290; - const T_IS_GREATER_OR_EQUAL = 291; - const T_SL = 292; - const T_SR = 293; - const T_INSTANCEOF = 294; - const T_INC = 295; - const T_DEC = 296; - const T_INT_CAST = 297; - const T_DOUBLE_CAST = 298; - const T_STRING_CAST = 299; - const T_ARRAY_CAST = 300; - const T_OBJECT_CAST = 301; - const T_BOOL_CAST = 302; - const T_UNSET_CAST = 303; - const T_POW = 304; - const T_NEW = 305; - const T_CLONE = 306; - const T_EXIT = 307; - const T_IF = 308; - const T_ELSEIF = 309; - const T_ELSE = 310; - const T_ENDIF = 311; - const T_LNUMBER = 312; - const T_DNUMBER = 313; - const T_STRING = 314; - const T_STRING_VARNAME = 315; - const T_VARIABLE = 316; - const T_NUM_STRING = 317; - const T_INLINE_HTML = 318; - const T_CHARACTER = 319; - const T_BAD_CHARACTER = 320; - const T_ENCAPSED_AND_WHITESPACE = 321; - const T_CONSTANT_ENCAPSED_STRING = 322; - const T_ECHO = 323; - const T_DO = 324; - const T_WHILE = 325; - const T_ENDWHILE = 326; - const T_FOR = 327; - const T_ENDFOR = 328; - const T_FOREACH = 329; - const T_ENDFOREACH = 330; - const T_DECLARE = 331; - const T_ENDDECLARE = 332; - const T_AS = 333; - const T_SWITCH = 334; + const T_THROW = 257; + const T_INCLUDE = 258; + const T_INCLUDE_ONCE = 259; + const T_EVAL = 260; + const T_REQUIRE = 261; + const T_REQUIRE_ONCE = 262; + const T_LOGICAL_OR = 263; + const T_LOGICAL_XOR = 264; + const T_LOGICAL_AND = 265; + const T_PRINT = 266; + const T_YIELD = 267; + const T_DOUBLE_ARROW = 268; + const T_YIELD_FROM = 269; + const T_PLUS_EQUAL = 270; + const T_MINUS_EQUAL = 271; + const T_MUL_EQUAL = 272; + const T_DIV_EQUAL = 273; + const T_CONCAT_EQUAL = 274; + const T_MOD_EQUAL = 275; + const T_AND_EQUAL = 276; + const T_OR_EQUAL = 277; + const T_XOR_EQUAL = 278; + const T_SL_EQUAL = 279; + const T_SR_EQUAL = 280; + const T_POW_EQUAL = 281; + const T_COALESCE_EQUAL = 282; + const T_COALESCE = 283; + const T_BOOLEAN_OR = 284; + const T_BOOLEAN_AND = 285; + const T_IS_EQUAL = 286; + const T_IS_NOT_EQUAL = 287; + const T_IS_IDENTICAL = 288; + const T_IS_NOT_IDENTICAL = 289; + const T_SPACESHIP = 290; + const T_IS_SMALLER_OR_EQUAL = 291; + const T_IS_GREATER_OR_EQUAL = 292; + const T_SL = 293; + const T_SR = 294; + const T_INSTANCEOF = 295; + const T_INC = 296; + const T_DEC = 297; + const T_INT_CAST = 298; + const T_DOUBLE_CAST = 299; + const T_STRING_CAST = 300; + const T_ARRAY_CAST = 301; + const T_OBJECT_CAST = 302; + const T_BOOL_CAST = 303; + const T_UNSET_CAST = 304; + const T_POW = 305; + const T_NEW = 306; + const T_CLONE = 307; + const T_EXIT = 308; + const T_IF = 309; + const T_ELSEIF = 310; + const T_ELSE = 311; + const T_ENDIF = 312; + const T_LNUMBER = 313; + const T_DNUMBER = 314; + const T_STRING = 315; + const T_STRING_VARNAME = 316; + const T_VARIABLE = 317; + const T_NUM_STRING = 318; + const T_INLINE_HTML = 319; + const T_ENCAPSED_AND_WHITESPACE = 320; + const T_CONSTANT_ENCAPSED_STRING = 321; + const T_ECHO = 322; + const T_DO = 323; + const T_WHILE = 324; + const T_ENDWHILE = 325; + const T_FOR = 326; + const T_ENDFOR = 327; + const T_FOREACH = 328; + const T_ENDFOREACH = 329; + const T_DECLARE = 330; + const T_ENDDECLARE = 331; + const T_AS = 332; + const T_SWITCH = 333; + const T_MATCH = 334; const T_ENDSWITCH = 335; const T_CASE = 336; const T_DEFAULT = 337; @@ -97,27 +97,27 @@ final class Tokens const T_TRY = 345; const T_CATCH = 346; const T_FINALLY = 347; - const T_THROW = 348; - const T_USE = 349; - const T_INSTEADOF = 350; - const T_GLOBAL = 351; - const T_STATIC = 352; - const T_ABSTRACT = 353; - const T_FINAL = 354; - const T_PRIVATE = 355; - const T_PROTECTED = 356; - const T_PUBLIC = 357; - const T_VAR = 358; - const T_UNSET = 359; - const T_ISSET = 360; - const T_EMPTY = 361; - const T_HALT_COMPILER = 362; - const T_CLASS = 363; - const T_TRAIT = 364; - const T_INTERFACE = 365; - const T_EXTENDS = 366; - const T_IMPLEMENTS = 367; - const T_OBJECT_OPERATOR = 368; + const T_USE = 348; + const T_INSTEADOF = 349; + const T_GLOBAL = 350; + const T_STATIC = 351; + const T_ABSTRACT = 352; + const T_FINAL = 353; + const T_PRIVATE = 354; + const T_PROTECTED = 355; + const T_PUBLIC = 356; + const T_VAR = 357; + const T_UNSET = 358; + const T_ISSET = 359; + const T_EMPTY = 360; + const T_HALT_COMPILER = 361; + const T_CLASS = 362; + const T_TRAIT = 363; + const T_INTERFACE = 364; + const T_EXTENDS = 365; + const T_IMPLEMENTS = 366; + const T_OBJECT_OPERATOR = 367; + const T_NULLSAFE_OBJECT_OPERATOR = 368; const T_LIST = 369; const T_ARRAY = 370; const T_CALLABLE = 371; @@ -127,20 +127,18 @@ final class Tokens const T_FUNC_C = 375; const T_LINE = 376; const T_FILE = 377; - const T_COMMENT = 378; - const T_DOC_COMMENT = 379; - const T_OPEN_TAG = 380; - const T_OPEN_TAG_WITH_ECHO = 381; - const T_CLOSE_TAG = 382; - const T_WHITESPACE = 383; - const T_START_HEREDOC = 384; - const T_END_HEREDOC = 385; - const T_DOLLAR_OPEN_CURLY_BRACES = 386; - const T_CURLY_OPEN = 387; - const T_PAAMAYIM_NEKUDOTAYIM = 388; - const T_NAMESPACE = 389; - const T_NS_C = 390; - const T_DIR = 391; - const T_NS_SEPARATOR = 392; - const T_ELLIPSIS = 393; + const T_START_HEREDOC = 378; + const T_END_HEREDOC = 379; + const T_DOLLAR_OPEN_CURLY_BRACES = 380; + const T_CURLY_OPEN = 381; + const T_PAAMAYIM_NEKUDOTAYIM = 382; + const T_NAMESPACE = 383; + const T_NS_C = 384; + const T_DIR = 385; + const T_NS_SEPARATOR = 386; + const T_ELLIPSIS = 387; + const T_NAME_FULLY_QUALIFIED = 388; + const T_NAME_QUALIFIED = 389; + const T_NAME_RELATIVE = 390; + const T_ATTRIBUTE = 391; } diff --git a/nikic/php-parser/lib/PhpParser/ParserAbstract.php b/nikic/php-parser/lib/PhpParser/ParserAbstract.php index 4d968cd3c..3ff474264 100644 --- a/nikic/php-parser/lib/PhpParser/ParserAbstract.php +++ b/nikic/php-parser/lib/PhpParser/ParserAbstract.php @@ -219,10 +219,7 @@ protected function doParse() { )); } - // This is necessary to assign some meaningful attributes to /* empty */ productions. They'll get - // the attributes of the next token, even though they don't contain it themselves. - $this->startAttributeStack[$stackPos+1] = $startAttributes; - $this->endAttributeStack[$stackPos+1] = $endAttributes; + // Allow productions to access the start attributes of the lookahead token. $this->lookaheadStartAttributes = $startAttributes; //$this->traceRead($symbol); @@ -294,7 +291,8 @@ protected function doParse() { /* Goto - shift nonterminal */ $lastEndAttributes = $this->endAttributeStack[$stackPos]; - $stackPos -= $this->ruleToLength[$rule]; + $ruleLength = $this->ruleToLength[$rule]; + $stackPos -= $ruleLength; $nonTerminal = $this->ruleToNonTerminal[$rule]; $idx = $this->gotoBase[$nonTerminal] + $stateStack[$stackPos]; if ($idx >= 0 && $idx < $this->gotoTableSize && $this->gotoCheck[$idx] === $nonTerminal) { @@ -307,6 +305,10 @@ protected function doParse() { $stateStack[$stackPos] = $state; $this->semStack[$stackPos] = $this->semValue; $this->endAttributeStack[$stackPos] = $lastEndAttributes; + if ($ruleLength === 0) { + // Empty productions use the start attributes of the lookahead token. + $this->startAttributeStack[$stackPos] = $this->lookaheadStartAttributes; + } } else { /* error */ switch ($this->errorState) { @@ -340,6 +342,7 @@ protected function doParse() { // We treat the error symbol as being empty, so we reset the end attributes // to the end attributes of the last non-error symbol + $this->startAttributeStack[$stackPos] = $this->lookaheadStartAttributes; $this->endAttributeStack[$stackPos] = $this->endAttributeStack[$stackPos - 1]; $this->endAttributes = $this->endAttributeStack[$stackPos - 1]; break; @@ -648,7 +651,7 @@ protected function fixupStartAttributes(Node $to, Node $from) { } protected function handleBuiltinTypes(Name $name) { - $scalarTypes = [ + $builtinTypes = [ 'bool' => true, 'int' => true, 'float' => true, @@ -658,6 +661,7 @@ protected function handleBuiltinTypes(Name $name) { 'object' => true, 'null' => true, 'false' => true, + 'mixed' => true, ]; if (!$name->isUnqualified()) { @@ -665,7 +669,7 @@ protected function handleBuiltinTypes(Name $name) { } $lowerName = $name->toLowerString(); - if (!isset($scalarTypes[$lowerName])) { + if (!isset($builtinTypes[$lowerName])) { return $name; } @@ -842,21 +846,29 @@ protected function parseDocString( } /** - * Create attributes for a zero-length node with the given start attributes. + * Create attributes for a zero-length common-capturing nop. * - * @param array $startAttributes + * @param Comment[] $comments * @return array */ - protected function createZeroLengthAttributes(array $startAttributes) { - $attributes = $startAttributes; - if (isset($startAttributes['startLine'])) { - $attributes['endLine'] = $startAttributes['startLine']; + protected function createCommentNopAttributes(array $comments) { + $comment = $comments[count($comments) - 1]; + $commentEndLine = $comment->getEndLine(); + $commentEndFilePos = $comment->getEndFilePos(); + $commentEndTokenPos = $comment->getEndTokenPos(); + + $attributes = ['comments' => $comments]; + if (-1 !== $commentEndLine) { + $attributes['startLine'] = $commentEndLine; + $attributes['endLine'] = $commentEndLine; } - if (isset($startAttributes['startTokenPos'])) { - $attributes['endTokenPos'] = $startAttributes['startTokenPos'] - 1; + if (-1 !== $commentEndFilePos) { + $attributes['startFilePos'] = $commentEndFilePos + 1; + $attributes['endFilePos'] = $commentEndFilePos; } - if (isset($startAttributes['startFilePos'])) { - $attributes['endFilePos'] = $startAttributes['startFilePos'] - 1; + if (-1 !== $commentEndTokenPos) { + $attributes['startTokenPos'] = $commentEndTokenPos + 1; + $attributes['endTokenPos'] = $commentEndTokenPos; } return $attributes; } @@ -889,13 +901,6 @@ protected function checkTryCatch(TryCatch $node) { } protected function checkNamespace(Namespace_ $node) { - if ($node->name && $node->name->isSpecialClassName()) { - $this->emitError(new Error( - sprintf('Cannot use \'%s\' as namespace name', $node->name), - $node->name->getAttributes() - )); - } - if (null !== $node->stmts) { foreach ($node->stmts as $stmt) { if ($stmt instanceof Namespace_) { diff --git a/nikic/php-parser/lib/PhpParser/PrettyPrinter/Standard.php b/nikic/php-parser/lib/PhpParser/PrettyPrinter/Standard.php index 133496f9b..636129d55 100644 --- a/nikic/php-parser/lib/PhpParser/PrettyPrinter/Standard.php +++ b/nikic/php-parser/lib/PhpParser/PrettyPrinter/Standard.php @@ -18,7 +18,9 @@ class Standard extends PrettyPrinterAbstract // Special nodes protected function pParam(Node\Param $node) { - return ($node->type ? $this->p($node->type) . ' ' : '') + return $this->pAttrGroups($node->attrGroups, true) + . $this->pModifiers($node->flags) + . ($node->type ? $this->p($node->type) . ' ' : '') . ($node->byRef ? '&' : '') . ($node->variadic ? '...' : '') . $this->p($node->var) @@ -26,7 +28,9 @@ protected function pParam(Node\Param $node) { } protected function pArg(Node\Arg $node) { - return ($node->byRef ? '&' : '') . ($node->unpack ? '...' : '') . $this->p($node->value); + return ($node->name ? $node->name->toString() . ': ' : '') + . ($node->byRef ? '&' : '') . ($node->unpack ? '...' : '') + . $this->p($node->value); } protected function pConst(Node\Const_ $node) { @@ -49,6 +53,15 @@ protected function pVarLikeIdentifier(Node\VarLikeIdentifier $node) { return '$' . $node->name; } + protected function pAttribute(Node\Attribute $node) { + return $this->p($node->name) + . ($node->args ? '(' . $this->pCommaSeparated($node->args) . ')' : ''); + } + + protected function pAttributeGroup(Node\AttributeGroup $node) { + return '#[' . $this->pCommaSeparated($node->attrs) . ']'; + } + // Names protected function pName(Name $node) { @@ -384,7 +397,10 @@ protected function pExpr_BinaryOp_Coalesce(BinaryOp\Coalesce $node) { } protected function pExpr_Instanceof(Expr\Instanceof_ $node) { - return $this->pInfixOp(Expr\Instanceof_::class, $node->expr, ' instanceof ', $node->class); + list($precedence, $associativity) = $this->precedenceMap[Expr\Instanceof_::class]; + return $this->pPrec($node->expr, $precedence, $associativity, -1) + . ' instanceof ' + . $this->pNewVariable($node->class); } // Unary expressions @@ -491,6 +507,11 @@ protected function pExpr_MethodCall(Expr\MethodCall $node) { . '(' . $this->pMaybeMultiline($node->args) . ')'; } + protected function pExpr_NullsafeMethodCall(Expr\NullsafeMethodCall $node) { + return $this->pDereferenceLhs($node->var) . '?->' . $this->pObjectProperty($node->name) + . '(' . $this->pMaybeMultiline($node->args) . ')'; + } + protected function pExpr_StaticCall(Expr\StaticCall $node) { return $this->pDereferenceLhs($node->class) . '::' . ($node->name instanceof Expr @@ -569,13 +590,17 @@ protected function pExpr_ConstFetch(Expr\ConstFetch $node) { } protected function pExpr_ClassConstFetch(Expr\ClassConstFetch $node) { - return $this->p($node->class) . '::' . $this->p($node->name); + return $this->pDereferenceLhs($node->class) . '::' . $this->p($node->name); } protected function pExpr_PropertyFetch(Expr\PropertyFetch $node) { return $this->pDereferenceLhs($node->var) . '->' . $this->pObjectProperty($node->name); } + protected function pExpr_NullsafePropertyFetch(Expr\NullsafePropertyFetch $node) { + return $this->pDereferenceLhs($node->var) . '?->' . $this->pObjectProperty($node->name); + } + protected function pExpr_StaticPropertyFetch(Expr\StaticPropertyFetch $node) { return $this->pDereferenceLhs($node->class) . '::$' . $this->pObjectProperty($node->name); } @@ -585,7 +610,8 @@ protected function pExpr_ShellExec(Expr\ShellExec $node) { } protected function pExpr_Closure(Expr\Closure $node) { - return ($node->static ? 'static ' : '') + return $this->pAttrGroups($node->attrGroups, true) + . ($node->static ? 'static ' : '') . 'function ' . ($node->byRef ? '&' : '') . '(' . $this->pCommaSeparated($node->params) . ')' . (!empty($node->uses) ? ' use(' . $this->pCommaSeparated($node->uses) . ')' : '') @@ -593,8 +619,21 @@ protected function pExpr_Closure(Expr\Closure $node) { . ' {' . $this->pStmts($node->stmts) . $this->nl . '}'; } + protected function pExpr_Match(Expr\Match_ $node) { + return 'match (' . $this->p($node->cond) . ') {' + . $this->pCommaSeparatedMultiline($node->arms, true) + . $this->nl + . '}'; + } + + protected function pMatchArm(Node\MatchArm $node) { + return ($node->conds ? $this->pCommaSeparated($node->conds) : 'default') + . ' => ' . $this->p($node->body); + } + protected function pExpr_ArrowFunction(Expr\ArrowFunction $node) { - return ($node->static ? 'static ' : '') + return $this->pAttrGroups($node->attrGroups, true) + . ($node->static ? 'static ' : '') . 'fn' . ($node->byRef ? '&' : '') . '(' . $this->pCommaSeparated($node->params) . ')' . (null !== $node->returnType ? ': ' . $this->p($node->returnType) : '') @@ -611,7 +650,8 @@ protected function pExpr_New(Expr\New_ $node) { $args = $node->args ? '(' . $this->pMaybeMultiline($node->args) . ')' : ''; return 'new ' . $this->pClassCommon($node->class, $args); } - return 'new ' . $this->p($node->class) . '(' . $this->pMaybeMultiline($node->args) . ')'; + return 'new ' . $this->pNewVariable($node->class) + . '(' . $this->pMaybeMultiline($node->args) . ')'; } protected function pExpr_Clone(Expr\Clone_ $node) { @@ -632,6 +672,10 @@ protected function pExpr_Exit(Expr\Exit_ $node) { . (null !== $node->expr ? '(' . $this->p($node->expr) . ')' : ''); } + protected function pExpr_Throw(Expr\Throw_ $node) { + return 'throw ' . $this->p($node->expr); + } + protected function pExpr_Yield(Expr\Yield_ $node) { if ($node->value === null) { return 'yield'; @@ -677,7 +721,8 @@ protected function pUseType($type) { } protected function pStmt_Interface(Stmt\Interface_ $node) { - return 'interface ' . $node->name + return $this->pAttrGroups($node->attrGroups) + . 'interface ' . $node->name . (!empty($node->extends) ? ' extends ' . $this->pCommaSeparated($node->extends) : '') . $this->nl . '{' . $this->pStmts($node->stmts) . $this->nl . '}'; } @@ -687,7 +732,8 @@ protected function pStmt_Class(Stmt\Class_ $node) { } protected function pStmt_Trait(Stmt\Trait_ $node) { - return 'trait ' . $node->name + return $this->pAttrGroups($node->attrGroups) + . 'trait ' . $node->name . $this->nl . '{' . $this->pStmts($node->stmts) . $this->nl . '}'; } @@ -712,7 +758,8 @@ protected function pStmt_TraitUseAdaptation_Alias(Stmt\TraitUseAdaptation\Alias } protected function pStmt_Property(Stmt\Property $node) { - return (0 === $node->flags ? 'var ' : $this->pModifiers($node->flags)) + return $this->pAttrGroups($node->attrGroups) + . (0 === $node->flags ? 'var ' : $this->pModifiers($node->flags)) . ($node->type ? $this->p($node->type) . ' ' : '') . $this->pCommaSeparated($node->props) . ';'; } @@ -723,9 +770,10 @@ protected function pStmt_PropertyProperty(Stmt\PropertyProperty $node) { } protected function pStmt_ClassMethod(Stmt\ClassMethod $node) { - return $this->pModifiers($node->flags) + return $this->pAttrGroups($node->attrGroups) + . $this->pModifiers($node->flags) . 'function ' . ($node->byRef ? '&' : '') . $node->name - . '(' . $this->pCommaSeparated($node->params) . ')' + . '(' . $this->pMaybeMultiline($node->params) . ')' . (null !== $node->returnType ? ' : ' . $this->p($node->returnType) : '') . (null !== $node->stmts ? $this->nl . '{' . $this->pStmts($node->stmts) . $this->nl . '}' @@ -733,12 +781,14 @@ protected function pStmt_ClassMethod(Stmt\ClassMethod $node) { } protected function pStmt_ClassConst(Stmt\ClassConst $node) { - return $this->pModifiers($node->flags) + return $this->pAttrGroups($node->attrGroups) + . $this->pModifiers($node->flags) . 'const ' . $this->pCommaSeparated($node->consts) . ';'; } protected function pStmt_Function(Stmt\Function_ $node) { - return 'function ' . ($node->byRef ? '&' : '') . $node->name + return $this->pAttrGroups($node->attrGroups) + . 'function ' . ($node->byRef ? '&' : '') . $node->name . '(' . $this->pCommaSeparated($node->params) . ')' . (null !== $node->returnType ? ' : ' . $this->p($node->returnType) : '') . $this->nl . '{' . $this->pStmts($node->stmts) . $this->nl . '}'; @@ -817,8 +867,8 @@ protected function pStmt_TryCatch(Stmt\TryCatch $node) { } protected function pStmt_Catch(Stmt\Catch_ $node) { - return 'catch (' . $this->pImplode($node->types, '|') . ' ' - . $this->p($node->var) + return 'catch (' . $this->pImplode($node->types, '|') + . ($node->var !== null ? ' ' . $this->p($node->var) : '') . ') {' . $this->pStmts($node->stmts) . $this->nl . '}'; } @@ -893,11 +943,12 @@ protected function pStmt_Nop(Stmt\Nop $node) { // Helpers protected function pClassCommon(Stmt\Class_ $node, $afterClassToken) { - return $this->pModifiers($node->flags) - . 'class' . $afterClassToken - . (null !== $node->extends ? ' extends ' . $this->p($node->extends) : '') - . (!empty($node->implements) ? ' implements ' . $this->pCommaSeparated($node->implements) : '') - . $this->nl . '{' . $this->pStmts($node->stmts) . $this->nl . '}'; + return $this->pAttrGroups($node->attrGroups, $node->name === null) + . $this->pModifiers($node->flags) + . 'class' . $afterClassToken + . (null !== $node->extends ? ' extends ' . $this->p($node->extends) : '') + . (!empty($node->implements) ? ' implements ' . $this->pCommaSeparated($node->implements) : '') + . $this->nl . '{' . $this->pStmts($node->stmts) . $this->nl . '}'; } protected function pObjectProperty($node) { @@ -980,11 +1031,16 @@ protected function pCallLhs(Node $node) { } } + protected function pNewVariable(Node $node) { + // TODO: This is not fully accurate. + return $this->pDereferenceLhs($node); + } + /** * @param Node[] $nodes * @return bool */ - private function hasNodeWithComments(array $nodes) { + protected function hasNodeWithComments(array $nodes) { foreach ($nodes as $node) { if ($node && $node->getComments()) { return true; @@ -993,11 +1049,21 @@ private function hasNodeWithComments(array $nodes) { return false; } - private function pMaybeMultiline(array $nodes, $trailingComma = false) { + protected function pMaybeMultiline(array $nodes, bool $trailingComma = false) { if (!$this->hasNodeWithComments($nodes)) { return $this->pCommaSeparated($nodes); } else { return $this->pCommaSeparatedMultiline($nodes, $trailingComma) . $this->nl; } } + + protected function pAttrGroups(array $nodes, bool $inline = false): string { + $result = ''; + $sep = $inline ? ' ' : $this->nl; + foreach ($nodes as $node) { + $result .= $this->p($node) . $sep; + } + + return $result; + } } diff --git a/nikic/php-parser/lib/PhpParser/PrettyPrinterAbstract.php b/nikic/php-parser/lib/PhpParser/PrettyPrinterAbstract.php index d554d6c03..804026eff 100644 --- a/nikic/php-parser/lib/PhpParser/PrettyPrinterAbstract.php +++ b/nikic/php-parser/lib/PhpParser/PrettyPrinterAbstract.php @@ -66,7 +66,7 @@ abstract class PrettyPrinterAbstract BinaryOp\BooleanAnd::class => [120, -1], BinaryOp\BooleanOr::class => [130, -1], BinaryOp\Coalesce::class => [140, 1], - Expr\Ternary::class => [150, -1], + Expr\Ternary::class => [150, 0], // parser uses %left for assignments, but they really behave as %right Expr\Assign::class => [160, 1], Expr\AssignRef::class => [160, 1], @@ -704,8 +704,10 @@ protected function pArray( $mapKey = $parentNodeType . '->' . $subNodeName; $insertStr = $this->listInsertionMap[$mapKey] ?? null; + $isStmtList = $subNodeName === 'stmts'; $beforeFirstKeepOrReplace = true; + $skipRemovedNode = false; $delayedAdd = []; $lastElemIndentLevel = $this->indentLevel; @@ -715,7 +717,7 @@ protected function pArray( $insertNewline = true; } - if ($subNodeName === 'stmts' && \count($origNodes) === 1 && \count($nodes) !== 1) { + if ($isStmtList && \count($origNodes) === 1 && \count($nodes) !== 1) { $startPos = $origNodes[0]->getStartTokenPos(); $endPos = $origNodes[0]->getEndTokenPos(); \assert($startPos >= 0 && $endPos >= 0); @@ -754,14 +756,7 @@ protected function pArray( $itemStartPos = $origArrItem->getStartTokenPos(); $itemEndPos = $origArrItem->getEndTokenPos(); - \assert($itemStartPos >= 0 && $itemEndPos >= 0); - - if ($itemEndPos < $itemStartPos) { - // End can be before start for Nop nodes, because offsets refer to non-whitespace - // locations, which for an "empty" node might result in an inverted order. - assert($origArrItem instanceof Stmt\Nop); - continue; - } + \assert($itemStartPos >= 0 && $itemEndPos >= 0 && $itemStartPos >= $pos); $origIndentLevel = $this->indentLevel; $lastElemIndentLevel = $this->origTokens->getIndentationBefore($itemStartPos) + $indentAdjustment; @@ -769,19 +764,28 @@ protected function pArray( $comments = $arrItem->getComments(); $origComments = $origArrItem->getComments(); - $commentStartPos = $origComments ? $origComments[0]->getTokenPos() : $itemStartPos; + $commentStartPos = $origComments ? $origComments[0]->getStartTokenPos() : $itemStartPos; \assert($commentStartPos >= 0); - $commentsChanged = $comments !== $origComments; - if ($commentsChanged) { - // Remove old comments - $itemStartPos = $commentStartPos; + if ($commentStartPos < $pos) { + // Comments may be assigned to multiple nodes if they start at the same position. + // Make sure we don't try to print them multiple times. + $commentStartPos = $itemStartPos; } - if (!empty($delayedAdd)) { + if ($skipRemovedNode) { + if ($isStmtList && $this->origTokens->haveBracesInRange($pos, $itemStartPos)) { + // We'd remove the brace of a code block. + // TODO: Preserve formatting. + $this->setIndentLevel($origIndentLevel); + return null; + } + } else { $result .= $this->origTokens->getTokenCode( $pos, $commentStartPos, $indentAdjustment); + } + if (!empty($delayedAdd)) { /** @var Node $delayedAddNode */ foreach ($delayedAdd as $delayedAddNode) { if ($insertNewline) { @@ -800,19 +804,20 @@ protected function pArray( } } - $result .= $this->origTokens->getTokenCode( - $commentStartPos, $itemStartPos, $indentAdjustment); - $delayedAdd = []; + } + + if ($comments !== $origComments) { + if ($comments) { + $result .= $this->pComments($comments) . $this->nl; + } } else { $result .= $this->origTokens->getTokenCode( - $pos, $itemStartPos, $indentAdjustment); + $commentStartPos, $itemStartPos, $indentAdjustment); } - if ($commentsChanged && $comments) { - // Add new comments - $result .= $this->pComments($comments) . $this->nl; - } + // If we had to remove anything, we have done so now. + $skipRemovedNode = false; } elseif ($diffType === DiffElem::TYPE_ADD) { if (null === $insertStr) { // We don't have insertion information for this list type @@ -846,18 +851,34 @@ protected function pArray( $result .= $insertStr; } } elseif ($diffType === DiffElem::TYPE_REMOVE) { - if ($i === 0) { - // TODO Handle removal at the start - return null; - } - if (!$origArrItem instanceof Node) { // We only support removal for nodes return null; } + $itemStartPos = $origArrItem->getStartTokenPos(); $itemEndPos = $origArrItem->getEndTokenPos(); - \assert($itemEndPos >= 0); + \assert($itemStartPos >= 0 && $itemEndPos >= 0); + + // Consider comments part of the node. + $origComments = $origArrItem->getComments(); + if ($origComments) { + $itemStartPos = $origComments[0]->getStartTokenPos(); + } + + if ($i === 0) { + // If we're removing from the start, keep the tokens before the node and drop those after it, + // instead of the other way around. + $result .= $this->origTokens->getTokenCode( + $pos, $itemStartPos, $indentAdjustment); + $skipRemovedNode = true; + } else { + if ($isStmtList && $this->origTokens->haveBracesInRange($pos, $itemStartPos)) { + // We'd remove the brace of a code block. + // TODO: Preserve formatting. + return null; + } + } $pos = $itemEndPos + 1; continue; @@ -876,6 +897,11 @@ protected function pArray( $pos = $itemEndPos + 1; } + if ($skipRemovedNode) { + // TODO: Support removing single node. + return null; + } + if (!empty($delayedAdd)) { if (!isset($this->emptyListInsertionMap[$mapKey])) { return null; @@ -1006,6 +1032,7 @@ protected function callLhsRequiresParens(Node $node) : bool { || $node instanceof Expr\ArrayDimFetch || $node instanceof Expr\FuncCall || $node instanceof Expr\MethodCall + || $node instanceof Expr\NullsafeMethodCall || $node instanceof Expr\StaticCall || $node instanceof Expr\Array_); } @@ -1022,9 +1049,11 @@ protected function dereferenceLhsRequiresParens(Node $node) : bool { || $node instanceof Node\Name || $node instanceof Expr\ArrayDimFetch || $node instanceof Expr\PropertyFetch + || $node instanceof Expr\NullsafePropertyFetch || $node instanceof Expr\StaticPropertyFetch || $node instanceof Expr\FuncCall || $node instanceof Expr\MethodCall + || $node instanceof Expr\NullsafeMethodCall || $node instanceof Expr\StaticCall || $node instanceof Expr\Array_ || $node instanceof Scalar\String_ @@ -1131,7 +1160,7 @@ protected function initializeFixupMap() { Expr\PostDec::class => ['var' => self::FIXUP_PREC_LEFT], Expr\Instanceof_::class => [ 'expr' => self::FIXUP_PREC_LEFT, - 'class' => self::FIXUP_PREC_RIGHT, + 'class' => self::FIXUP_PREC_RIGHT, // TODO: FIXUP_NEW_VARIABLE ], Expr\Ternary::class => [ 'cond' => self::FIXUP_PREC_LEFT, @@ -1141,10 +1170,16 @@ protected function initializeFixupMap() { Expr\FuncCall::class => ['name' => self::FIXUP_CALL_LHS], Expr\StaticCall::class => ['class' => self::FIXUP_DEREF_LHS], Expr\ArrayDimFetch::class => ['var' => self::FIXUP_DEREF_LHS], + Expr\ClassConstFetch::class => ['var' => self::FIXUP_DEREF_LHS], + Expr\New_::class => ['class' => self::FIXUP_DEREF_LHS], // TODO: FIXUP_NEW_VARIABLE Expr\MethodCall::class => [ 'var' => self::FIXUP_DEREF_LHS, 'name' => self::FIXUP_BRACED_NAME, ], + Expr\NullsafeMethodCall::class => [ + 'var' => self::FIXUP_DEREF_LHS, + 'name' => self::FIXUP_BRACED_NAME, + ], Expr\StaticPropertyFetch::class => [ 'class' => self::FIXUP_DEREF_LHS, 'name' => self::FIXUP_VAR_BRACED_NAME, @@ -1153,6 +1188,10 @@ protected function initializeFixupMap() { 'var' => self::FIXUP_DEREF_LHS, 'name' => self::FIXUP_BRACED_NAME, ], + Expr\NullsafePropertyFetch::class => [ + 'var' => self::FIXUP_DEREF_LHS, + 'name' => self::FIXUP_BRACED_NAME, + ], Scalar\Encapsed::class => [ 'parts' => self::FIXUP_ENCAPSED, ], @@ -1227,6 +1266,7 @@ protected function initializeRemovalMap() { 'Param->type' => $stripRight, 'Param->default' => $stripEquals, 'Stmt_Break->num' => $stripBoth, + 'Stmt_Catch->var' => $stripLeft, 'Stmt_ClassMethod->returnType' => $stripColon, 'Stmt_Class->extends' => ['left' => \T_EXTENDS], 'Expr_PrintableNewAnonClass->extends' => ['left' => \T_EXTENDS], @@ -1264,6 +1304,7 @@ protected function initializeInsertionMap() { 'Param->type' => [null, false, null, ' '], 'Param->default' => [null, false, ' = ', null], 'Stmt_Break->num' => [\T_BREAK, false, ' ', null], + 'Stmt_Catch->var' => [null, false, ' ', null], 'Stmt_ClassMethod->returnType' => [')', false, ' : ', null], 'Stmt_Class->extends' => [null, false, ' extends ', null], 'Expr_PrintableNewAnonClass->extends' => [null, ' extends ', null], @@ -1308,6 +1349,7 @@ protected function initializeListInsertionMap() { 'Expr_Isset->vars' => ', ', 'Expr_List->items' => ', ', 'Expr_MethodCall->args' => ', ', + 'Expr_NullsafeMethodCall->args' => ', ', 'Expr_New->args' => ', ', 'Expr_PrintableNewAnonClass->args' => ', ', 'Expr_StaticCall->args' => ', ', @@ -1325,12 +1367,15 @@ protected function initializeListInsertionMap() { 'Stmt_Global->vars' => ', ', 'Stmt_GroupUse->uses' => ', ', 'Stmt_Interface->extends' => ', ', + 'Stmt_Match->arms' => ', ', 'Stmt_Property->props' => ', ', 'Stmt_StaticVar->vars' => ', ', 'Stmt_TraitUse->traits' => ', ', 'Stmt_TraitUseAdaptation_Precedence->insteadof' => ', ', 'Stmt_Unset->vars' => ', ', 'Stmt_Use->uses' => ', ', + 'MatchArm->conds' => ', ', + 'AttributeGroup->attrs' => ', ', // statement lists 'Expr_Closure->stmts' => "\n", @@ -1351,6 +1396,17 @@ protected function initializeListInsertionMap() { 'Stmt_Function->stmts' => "\n", 'Stmt_If->stmts' => "\n", 'Stmt_Namespace->stmts' => "\n", + 'Stmt_Class->attrGroups' => "\n", + 'Stmt_Interface->attrGroups' => "\n", + 'Stmt_Trait->attrGroups' => "\n", + 'Stmt_Function->attrGroups' => "\n", + 'Stmt_ClassMethod->attrGroups' => "\n", + 'Stmt_ClassConst->attrGroups' => "\n", + 'Stmt_Property->attrGroups' => "\n", + 'Expr_PrintableNewAnonClass->attrGroups' => ' ', + 'Expr_Closure->attrGroups' => ' ', + 'Expr_ArrowFunction->attrGroups' => ' ', + 'Param->attrGroups' => ' ', 'Stmt_Switch->cases' => "\n", 'Stmt_TraitUse->adaptations' => "\n", 'Stmt_TryCatch->stmts' => "\n", @@ -1373,6 +1429,7 @@ protected function initializeEmptyListInsertionMap() { 'Expr_Closure->params' => ['(', '', ''], 'Expr_FuncCall->args' => ['(', '', ''], 'Expr_MethodCall->args' => ['(', '', ''], + 'Expr_NullsafeMethodCall->args' => ['(', '', ''], 'Expr_New->args' => ['(', '', ''], 'Expr_PrintableNewAnonClass->args' => ['(', '', ''], 'Expr_PrintableNewAnonClass->implements' => [null, ' implements ', ''], @@ -1420,6 +1477,7 @@ protected function initializeModifierChangeMap() { 'Stmt_ClassMethod->flags' => \T_FUNCTION, 'Stmt_Class->flags' => \T_CLASS, 'Stmt_Property->flags' => \T_VARIABLE, + 'Param->flags' => \T_VARIABLE, //'Stmt_TraitUseAdaptation_Alias->newModifier' => 0, // TODO ];