Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitf503e37

Browse files
committed
[PropertyInfo] Fix multi phpdoc covered promoted properties
1 parent1605b57 commitf503e37

File tree

1 file changed

+8
-4
lines changed

1 file changed

+8
-4
lines changed

‎src/Symfony/Component/PropertyInfo/Extractor/PhpStanExtractor.php‎

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,14 @@ public function getTypes(string $class, string $property, array $context = []):
9999
continue;
100100
}
101101

102+
if (
103+
$tagDocNode->valueinstanceof ParamTagValueNode
104+
&&null ===$prefix
105+
&&$tagDocNode->value->parameterName !=='$'.$property
106+
) {
107+
continue;
108+
}
109+
102110
foreach ($this->phpStanTypeHelper->getTypes($tagDocNode->value,$nameScope)as$type) {
103111
switch ($type->getClassName()) {
104112
case'self':
@@ -239,10 +247,6 @@ private function getDocBlockFromProperty(string $class, string $property): ?arra
239247
$phpDocNode =$this->phpDocParser->parse($tokens);
240248
$tokens->consumeTokenType(Lexer::TOKEN_END);
241249

242-
if (self::MUTATOR ===$source && !$this->filterDocBlockParams($phpDocNode,$property)) {
243-
returnnull;
244-
}
245-
246250
return [$phpDocNode,$source,$reflectionProperty->class];
247251
}
248252

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp