Home
last modified time | relevance | path

Searched refs:emulator (Results 1 – 2 of 2) sorted by relevance

/PHP-Parser/lib/PhpParser/Lexer/TokenEmulator/
H A DReverseEmulator.php12 private TokenEmulator $emulator; variable in PhpParser\\Lexer\\TokenEmulator\\ReverseEmulator
14 public function __construct(TokenEmulator $emulator) { argument
15 $this->emulator = $emulator;
19 return $this->emulator->getPhpVersion();
23 return $this->emulator->isEmulationNeeded($code);
27 return $this->emulator->reverseEmulate($code, $tokens);
31 return $this->emulator->emulate($code, $tokens);
/PHP-Parser/lib/PhpParser/Lexer/
H A DEmulative.php54 foreach ($emulators as $emulator) {
55 $emulatorPhpVersion = $emulator->getPhpVersion();
57 $this->emulators[] = $emulator;
59 $this->emulators[] = new ReverseEmulator($emulator);
65 $emulators = array_filter($this->emulators, function ($emulator) use ($code) {
66 return $emulator->isEmulationNeeded($code);
79 foreach ($emulators as $emulator) {
80 $code = $emulator->preprocessCode($code, $this->patches);
96 foreach ($emulators as $emulator) {
97 $tokens = $emulator->emulate($code, $tokens);

Completed in 5 milliseconds