Skip to content

Commit

Permalink
remove obsolete test and fix a missing exception
Browse files Browse the repository at this point in the history
  • Loading branch information
orklah committed Jan 5, 2022
1 parent 135bee9 commit cc19154
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 8 deletions.
3 changes: 3 additions & 0 deletions src/Psalm/Internal/Type/ParseTreeCreator.php
Expand Up @@ -757,7 +757,10 @@ private function handleValue(array $type_token): void
if ($nexter_token !== null && $nexter_token[0] === '}') {
$new_leaf->terminated = true;
++$this->t;
} elseif ($nexter_token === null) {
throw new TypeParseTreeException('Unclosed bracket in keyed array');
}

break;

case '(':
Expand Down
8 changes: 0 additions & 8 deletions tests/AnnotationTest.php
Expand Up @@ -1652,14 +1652,6 @@ public function bar() {
',
'error_message' => 'UndefinedDocblockClass',
],
'preventBadTKeyedArrayFormat' => [
'<?php
/**
* @param array{} $arr
*/
function bar(array $arr): void {}',
'error_message' => 'InvalidDocblock',
],
'noPhpStormAnnotationsThankYou' => [
'<?php
/** @param ArrayIterator|string[] $i */
Expand Down

0 comments on commit cc19154

Please sign in to comment.