X7ROOT File Manager
Current Path:
/opt/cpanel/ea-wappspector/vendor/nikic/php-parser/lib/PhpParser
opt
/
cpanel
/
ea-wappspector
/
vendor
/
nikic
/
php-parser
/
lib
/
PhpParser
/
??
..
??
Builder
??
Builder.php
(202 B)
??
BuilderFactory.php
(10.3 KB)
??
BuilderHelpers.php
(9.73 KB)
??
Comment
??
Comment.php
(6.75 KB)
??
ConstExprEvaluationException.php
(112 B)
??
ConstExprEvaluator.php
(9.33 KB)
??
Error.php
(4.84 KB)
??
ErrorHandler
??
ErrorHandler.php
(300 B)
??
Internal
??
JsonDecoder.php
(3.44 KB)
??
Lexer
??
Lexer.php
(4.26 KB)
??
Modifiers.php
(2.71 KB)
??
NameContext.php
(9.82 KB)
??
Node
??
Node.php
(4.03 KB)
??
NodeAbstract.php
(5.24 KB)
??
NodeDumper.php
(10.24 KB)
??
NodeFinder.php
(2.55 KB)
??
NodeTraverser.php
(10.09 KB)
??
NodeTraverserInterface.php
(598 B)
??
NodeVisitor
??
NodeVisitor.php
(4.08 KB)
??
NodeVisitorAbstract.php
(447 B)
??
Parser
??
Parser.php
(765 B)
??
ParserAbstract.php
(51.59 KB)
??
ParserFactory.php
(1.41 KB)
??
PhpVersion.php
(4.73 KB)
??
PrettyPrinter
??
PrettyPrinter.php
(1.66 KB)
??
PrettyPrinterAbstract.php
(71.24 KB)
??
Token.php
(487 B)
??
compatibility_tokens.php
(2.46 KB)
Editing: compatibility_tokens.php
<?php declare(strict_types=1); namespace PhpParser; if (!\function_exists('PhpParser\defineCompatibilityTokens')) { function defineCompatibilityTokens(): void { $compatTokens = [ // PHP 8.0 'T_NAME_QUALIFIED', 'T_NAME_FULLY_QUALIFIED', 'T_NAME_RELATIVE', 'T_MATCH', 'T_NULLSAFE_OBJECT_OPERATOR', 'T_ATTRIBUTE', // PHP 8.1 'T_ENUM', 'T_AMPERSAND_NOT_FOLLOWED_BY_VAR_OR_VARARG', 'T_AMPERSAND_FOLLOWED_BY_VAR_OR_VARARG', 'T_READONLY', // PHP 8.4 'T_PROPERTY_C', 'T_PUBLIC_SET', 'T_PROTECTED_SET', 'T_PRIVATE_SET', // PHP 8.5 'T_PIPE', 'T_VOID_CAST', ]; // 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); if (!\is_int($tokenId)) { throw new \Error(sprintf( 'Token %s has ID of type %s, should be int. ' . 'You may be using a library with broken token emulation', $token, \gettype($tokenId) )); } $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--; } } } defineCompatibilityTokens(); }
Upload File
Create Folder