CloneableFinalInstantiable
ImplementsPhpParser\Lexer\TokenEmulator\TokenEmulatorInterface
Constants
public PhpParser\Lexer\TokenEmulator\NumericLiteralSeparatorEmulator::BIN = '(?:0b[01]+(?:_[01]+)*)'
public PhpParser\Lexer\TokenEmulator\NumericLiteralSeparatorEmulator::DEC = '(?:[0-9]+(?:_[0-9]+)*)'
public PhpParser\Lexer\TokenEmulator\NumericLiteralSeparatorEmulator::EXP = '(?:e[+-]?(?:[0-9]+(?:_[0-9]+)*))'
public PhpParser\Lexer\TokenEmulator\NumericLiteralSeparatorEmulator::FLOAT = '(?:(?:(?:[0-9]+(?:_[0-9]+)*)\.(?:[0-9]+(?:_[0-9]+)*)?|\.(?:[0-9]+(?:_[0-9]+)*))(?:e[+-]?(?:[0-9]+(?:_[0-9]+)*))?|(?:[0-9]+(?:_[0-9]+)*)(?:e[+-]?(?:[0-9]+(?:_[0-9]+)*)))'
public PhpParser\Lexer\TokenEmulator\NumericLiteralSeparatorEmulator::HEX = '(?:0x[0-9a-f]+(?:_[0-9a-f]+)*)'
public PhpParser\Lexer\TokenEmulator\NumericLiteralSeparatorEmulator::NUMBER = '~(?:(?:(?:[0-9]+(?:_[0-9]+)*)\.(?:[0-9]+(?:_[0-9]+)*)?|\.(?:[0-9]+(?:_[0-9]+)*))(?:e[+-]?(?:[0-9]+(?:_[0-9]+)*))?|(?:[0-9]+(?:_[0-9]+)*)(?:e[+-]?(?:[0-9]+(?:_[0-9]+)*)))|(?:0b[01]+(?:_[01]+)*)|(?:0x[0-9a-f]+(?:_[0-9a-f]+)*)|(?:[0-9]+(?:_[0-9]+)*)~iA'
public PhpParser\Lexer\TokenEmulator\NumericLiteralSeparatorEmulator::SIMPLE_FLOAT = '(?:(?:[0-9]+(?:_[0-9]+)*)\.(?:[0-9]+(?:_[0-9]+)*)?|\.(?:[0-9]+(?:_[0-9]+)*))'
Methods
public emulate(string $code, array $tokens) : array
public getPhpVersion() : string
public isEmulationNeeded(string $code) : bool
public reverseEmulate(string $code, array $tokens) : array
Methods
private resolveIntegerOrFloatToken(string $str) : int
© 2020 Bruce Wells
Search Namespaces \ Classes
ConfigurationNumbers (0-9.) only