Skip to content

Commit

Permalink
Use new constants self-references
Browse files Browse the repository at this point in the history
  • Loading branch information
Wirone committed Sep 27, 2023
1 parent 8146bf7 commit 4e24664
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/Tokenizer/Tokens.php
Original file line number Diff line number Diff line change
Expand Up @@ -227,19 +227,19 @@ public static function fromCode(string $code): self
public static function getBlockEdgeDefinitions(): array
{
$definitions = [
self::BLOCK_TYPE_CURLY_BRACE => [
self::BLOCK_TYPE_BRACE => [
'start' => '{',
'end' => '}',
],
self::BLOCK_TYPE_PARENTHESIS_BRACE => [
self::BLOCK_TYPE_PARENTHESIS => [
'start' => '(',
'end' => ')',
],
self::BLOCK_TYPE_INDEX_SQUARE_BRACE => [
self::BLOCK_TYPE_INDEX_BRACKET => [
'start' => '[',
'end' => ']',
],
self::BLOCK_TYPE_ARRAY_SQUARE_BRACE => [
self::BLOCK_TYPE_ARRAY_BRACKET => [
'start' => [CT::T_ARRAY_SQUARE_BRACE_OPEN, '['],
'end' => [CT::T_ARRAY_SQUARE_BRACE_CLOSE, ']'],
],
Expand All @@ -259,11 +259,11 @@ public static function getBlockEdgeDefinitions(): array
'start' => [CT::T_GROUP_IMPORT_BRACE_OPEN, '{'],
'end' => [CT::T_GROUP_IMPORT_BRACE_CLOSE, '}'],
],
self::BLOCK_TYPE_DESTRUCTURING_SQUARE_BRACE => [
self::BLOCK_TYPE_DESTRUCTURING_BRACKET => [
'start' => [CT::T_DESTRUCTURING_SQUARE_BRACE_OPEN, '['],
'end' => [CT::T_DESTRUCTURING_SQUARE_BRACE_CLOSE, ']'],
],
self::BLOCK_TYPE_BRACE_CLASS_INSTANTIATION => [
self::BLOCK_TYPE_PARENTHESIS_CLASS_INSTANTIATION => [
'start' => [CT::T_BRACE_CLASS_INSTANTIATION_OPEN, '('],
'end' => [CT::T_BRACE_CLASS_INSTANTIATION_CLOSE, ')'],
],
Expand Down

0 comments on commit 4e24664

Please sign in to comment.