forked from microsoft/tolerant-php-parser
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathMissingToken.php
More file actions
23 lines (19 loc) · 816 Bytes
/
MissingToken.php
File metadata and controls
23 lines (19 loc) · 816 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
<?php
/*---------------------------------------------------------------------------------------------
* Copyright (c) Microsoft Corporation. All rights reserved.
* Licensed under the MIT License. See License.txt in the project root for license information.
*--------------------------------------------------------------------------------------------*/
namespace Microsoft\PhpParser;
use ReturnTypeWillChange;
class MissingToken extends Token {
public function __construct(int $kind, int $fullStart) {
parent::__construct($kind, $fullStart, $fullStart, 0);
}
#[ReturnTypeWillChange]
public function jsonSerialize() {
return array_merge(
["error" => $this->getTokenKindNameFromValue(TokenKind::MissingToken)],
parent::jsonSerialize()
);
}
}