Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove @psalm-generator-return annotation #7853

Merged
merged 1 commit into from Apr 13, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/Psalm/DocComment.php
Expand Up @@ -24,7 +24,7 @@ final class DocComment
'assert', 'assert-if-true', 'assert-if-false', 'suppress',
'ignore-nullable-return', 'override-property-visibility',
'override-method-visibility', 'seal-properties', 'seal-methods',
'generator-return', 'ignore-falsable-return', 'variadic', 'pure',
'ignore-falsable-return', 'variadic', 'pure',
'ignore-variable-method', 'ignore-variable-property', 'internal',
'taint-sink', 'taint-source', 'assert-untainted', 'scope-this',
'mutation-free', 'external-mutation-free', 'immutable', 'readonly',
Expand Down
1 change: 0 additions & 1 deletion tests/DocumentationTest.php
Expand Up @@ -76,7 +76,6 @@ class DocumentationTest extends TestCase
'@psalm-assert-untainted',
'@psalm-consistent-constructor',
'@psalm-flow',
'@psalm-generator-return',
'@psalm-ignore-variable-method',
'@psalm-ignore-variable-property',
'@psalm-override-method-visibility',
Expand Down
14 changes: 0 additions & 14 deletions tests/GeneratorTest.php
Expand Up @@ -53,20 +53,6 @@ function g():Generator { yield new stdClass; }
'$g' => 'Generator<int, stdClass, mixed, mixed>',
],
],
'generatorWithReturn' => [
'code' => '<?php
/**
* @return Generator<int,int>
* @psalm-generator-return string
*/
function fooFoo(int $i): Generator {
if ($i === 1) {
return "bash";
}

yield 1;
}',
],
'generatorSend' => [
'code' => '<?php
/** @return Generator<int, string, DateTimeInterface, void> */
Expand Down