Skip to content

[Php80] Remove AstResolver usage on AddParamBasedOnParentClassMethodRector#8196

Open
samsonasik wants to merge 1 commit into
mainfrom
remov-add-
Open

[Php80] Remove AstResolver usage on AddParamBasedOnParentClassMethodRector#8196
samsonasik wants to merge 1 commit into
mainfrom
remov-add-

Conversation

@samsonasik

Copy link
Copy Markdown
Member

No description provided.

@samsonasik
samsonasik requested a review from TomasVotruba July 19, 2026 16:36
@samsonasik

Copy link
Copy Markdown
Member Author

@TomasVotruba ready 👍

/**
* @return AttributeGroup[]
*/
private function createAttributeGroups(ReflectionParameter $reflectionParameter): array

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is this for? Seems unnecessary.

What fixture would fail without it?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

there is existing fixture for that

namespace Rector\Tests\Php80\Rector\ClassMethod\AddParamBasedOnParentClassMethodRector\Fixture;
// when there is no \mysqli class, it may pull from scoper phar file
final class ExtendsMysqli extends \mysqli
{
public function query($query) {
//Code
}
}
?>
-----
<?php
namespace Rector\Tests\Php80\Rector\ClassMethod\AddParamBasedOnParentClassMethodRector\Fixture;
// when there is no \mysqli class, it may pull from scoper phar file
final class ExtendsMysqli extends \mysqli
{
public function query($query,
#[\JetBrains\PhpStorm\Internal\PhpStormStubsElementAvailable(from: '7.1')]
int $result_mode = \MYSQLI_STORE_RESULT) {
//Code
}
}

originally from PR and issue:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants