Skip to content

Commit

Permalink
chore(deps): update dependency vimeo/psalm to v5.23.1 (#219)
Browse files Browse the repository at this point in the history
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: M.P. Korstanje <[email protected]>
  • Loading branch information
renovate[bot] and mpkorstanje authored Mar 17, 2024
1 parent 1e60601 commit c22cfaa
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
2 changes: 1 addition & 1 deletion php/composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
},
"require-dev": {
"phpunit/phpunit": "^10.5",
"vimeo/psalm": "5.19.1",
"vimeo/psalm": "5.23.1",
"friendsofphp/php-cs-fixer": "^3.51",
"psalm/plugin-phpunit": "^0.19.0"
},
Expand Down
2 changes: 1 addition & 1 deletion php/src/PickleCompiler.php
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ private function pickleDataTable(DataTable $dataTable, array $variableCells, arr
private function pickleDocString(DocString $docstring, array $variableCells, array $valueCells): PickleDocString
{
return new PickleDocString(
mediaType: $docstring->mediaType ? $this->interpolate($docstring->mediaType, $variableCells, $valueCells) : null,
mediaType: $docstring->mediaType !== null ? $this->interpolate($docstring->mediaType, $variableCells, $valueCells) : null,
content: $this->interpolate($docstring->content, $variableCells, $valueCells),
);
}
Expand Down
3 changes: 2 additions & 1 deletion php/src/TokenFormatter.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,13 @@ public function formatToken(Token $token): string
return 'EOF';
}

$keyword = $token->match?->keyword;
return sprintf(
"(%s:%s)%s:%s/%s/%s",
$token->getLocation()->line,
$token->getLocation()->column,
$token->match?->tokenType->name ?? '',
$token->match?->keyword ? $this->formatKeyword($token) : '',
$keyword !== null && $keyword !== '' ? $this->formatKeyword($token) : '',
$token->match?->text ?? '',
$token->match === null ? ''
: join(',', array_map(fn ($linespan) => $linespan->column . ':' . $linespan->text, $token->match->items)),
Expand Down

0 comments on commit c22cfaa

Please sign in to comment.