diff --git a/src/Psalm/Internal/LanguageServer/LanguageServer.php b/src/Psalm/Internal/LanguageServer/LanguageServer.php index 3a049a62040..30c48becdad 100644 --- a/src/Psalm/Internal/LanguageServer/LanguageServer.php +++ b/src/Psalm/Internal/LanguageServer/LanguageServer.php @@ -417,6 +417,7 @@ function (IssueData $issue_data): Diagnostic { } else { // the Diagnostic constructor only takes `int` for the code, but the property can be // `int` or `string`, so we set the property directly because we want to use a `string` + /** @psalm-suppress InvalidPropertyAssignmentValue */ $diagnostic->code = $code; } diff --git a/src/Psalm/Internal/LanguageServer/Server/TextDocument.php b/src/Psalm/Internal/LanguageServer/Server/TextDocument.php index e4b4d1b941f..46cbabe9834 100644 --- a/src/Psalm/Internal/LanguageServer/Server/TextDocument.php +++ b/src/Psalm/Internal/LanguageServer/Server/TextDocument.php @@ -378,18 +378,6 @@ public function codeAction(TextDocumentIdentifier $textDocument, Range $range): $indentation = $matches[1] ?? ''; } - - /** - * Suppress Psalm because ther are bugs in how - * LanguageServer's signature of WorkspaceEdit is declared: - * - * See: - * https://github.com/felixfbecker/php-language-server-protocol - * See: - * https://microsoft.github.io/language-server-protocol/specifications/specification-3-17/#workspaceEdit - * - * @psalm-suppress InvalidArgument - */ $edit = new WorkspaceEdit([ $textDocument->uri => [ new TextEdit(