2020-07-15 21:40:05 +02:00
|
|
|
<?php declare(strict_types=1);
|
|
|
|
|
|
|
|
namespace PhpParser\Lexer\TokenEmulator;
|
|
|
|
|
|
|
|
use PhpParser\Lexer\Emulative;
|
|
|
|
|
2020-08-01 22:02:52 +02:00
|
|
|
final class MatchTokenEmulator extends KeywordEmulator
|
2020-07-15 21:40:05 +02:00
|
|
|
{
|
2020-08-01 21:49:53 +02:00
|
|
|
public function getPhpVersion(): string
|
2020-07-15 21:40:05 +02:00
|
|
|
{
|
2020-08-01 21:49:53 +02:00
|
|
|
return Emulative::PHP_8_0;
|
|
|
|
}
|
2020-07-15 21:40:05 +02:00
|
|
|
|
2020-08-01 22:02:52 +02:00
|
|
|
public function getKeywordString(): string
|
2020-08-01 21:49:53 +02:00
|
|
|
{
|
2020-08-01 22:02:52 +02:00
|
|
|
return 'match';
|
2020-07-15 21:40:05 +02:00
|
|
|
}
|
|
|
|
|
2020-08-01 22:02:52 +02:00
|
|
|
public function getKeywordToken(): int
|
2020-07-15 21:40:05 +02:00
|
|
|
{
|
2020-08-01 22:34:36 +02:00
|
|
|
return \T_MATCH;
|
2020-07-15 21:40:05 +02:00
|
|
|
}
|
|
|
|
}
|