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

Fix incorrect warnings for the PSR1 hint [GH-7458] #7461

Merged

Conversation

junichi11
Copy link
Member

Example:

class GH7458 {
    public function __debugInfo(): array {}
    public function __serialize(): array {}
    public function __unserialize(array $data): void {}
}

Before:

nb-php-gh-7458-before

After:

nb-php-gh-7458-after

- apache#7458
- Ignore `__debugInfo`, `__serialize`, and ` __unserialize` magic methods
- Fix the unit test

Example:
```php
class GH7458 {
    public function __debugInfo(): array {}
    public function __serialize(): array {}
    public function __unserialize(array $data): void {}
}
```
@junichi11 junichi11 added the PHP [ci] enable extra PHP tests (php/php.editor) label Jun 12, 2024
@junichi11 junichi11 added this to the NB23 milestone Jun 12, 2024
@junichi11 junichi11 linked an issue Jun 12, 2024 that may be closed by this pull request
@junichi11 junichi11 requested a review from tmysik June 14, 2024 02:42
@junichi11 junichi11 merged commit 6527316 into apache:master Jun 14, 2024
33 checks passed
@junichi11 junichi11 deleted the php-gh-7458-incorrect-psr1-warning branch June 14, 2024 12:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PHP [ci] enable extra PHP tests (php/php.editor)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[PHP] Warning for magic methods
2 participants