Skip to content

fix: use PHP 7.4 compatible syntax in attribute classes#1847

Merged
spawnia merged 4 commits intomasterfrom
1843-php74-syntax-compatibility
Feb 5, 2026
Merged

fix: use PHP 7.4 compatible syntax in attribute classes#1847
spawnia merged 4 commits intomasterfrom
1843-php74-syntax-compatibility

Conversation

@spawnia
Copy link
Copy Markdown
Collaborator

@spawnia spawnia commented Feb 5, 2026

Summary

  • Remove PHPStan exclusions for Deprecated.php and Description.php so the existing PHP 7.4 CI job can detect issues
  • Expand constructor promotion to traditional property declaration and assignment

This makes the files parseable by tools running on PHP 7.4 (stub generators, static analyzers).

Fixes #1843

🤖 Generated with Claude Code

spawnia and others added 3 commits February 5, 2026 16:45
See if existing PHP 7.4 CI catches constructor promotion syntax.

Related: #1843

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
Expand constructor promotion to traditional property declaration
and assignment, making these files parseable by tools running on
PHP 7.4.

Fixes #1843

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@spawnia spawnia changed the title test: remove PHPStan exclusions to verify PHP 7.4 CI detection fix: use PHP 7.4 compatible syntax in attribute classes Feb 5, 2026
Trailing commas in function/method parameter lists are only available
since PHP 8.0.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@spawnia spawnia added the bug label Feb 5, 2026
@spawnia spawnia marked this pull request as ready for review February 5, 2026 16:02
@spawnia spawnia merged commit 13a1fff into master Feb 5, 2026
20 checks passed
@spawnia spawnia deleted the 1843-php74-syntax-compatibility branch February 5, 2026 16:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

GraphQL\Type\Definition\Deprecated constructor promotion fails PHP7.4 lints

1 participant