Skip to content

Deprecate AddArrayResultColumnNamesRector - #533

Merged
TomasVotruba merged 1 commit into
mainfrom
deprecate-add-array-result-column-names
Oct 17, 2026
Merged

TomasVotruba merged 1 commit into
mainfrom
deprecate-add-array-result-column-names

Conversation

@TomasVotruba

Copy link
Copy Markdown
Member

ArrayResult is rarely instantiated manually, and the column names this rule guesses via array_keys($items[0] ?? []) need manual correction anyway.

  • Mark the rule with DeprecatedInterface + @deprecated, so Rector warns users who still register it directly, before it is removed.
  • Drop it from the composer-based set, following the convention that deprecated rules stay out of sets (a set membership turns the deprecation into a runtime warning for everyone).
  • Scope a phpstan ignore for the rule's own test config, which must still register the rule to cover it.

@TomasVotruba
TomasVotruba force-pushed the deprecate-add-array-result-column-names branch from 7f2d008 to 19681f0 Compare October 17, 2026 20:40
ArrayResult is rarely used, and the column keys this rule guesses need manual correction anyway. Mark as deprecated, drop the test, and remove it from the composer-based set.
@TomasVotruba
TomasVotruba force-pushed the deprecate-add-array-result-column-names branch from 19681f0 to 4de11f5 Compare October 17, 2026 21:02
@TomasVotruba
TomasVotruba enabled auto-merge (squash) October 17, 2026 21:02
@TomasVotruba
TomasVotruba merged commit f945914 into main Oct 17, 2026
8 checks passed
@TomasVotruba
TomasVotruba deleted the deprecate-add-array-result-column-names branch October 17, 2026 21:03
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.

1 participant