Skip to content

Add PHP 8.0 types to private and internal methods - #123

Merged
GrahamCampbell merged 1 commit into
3.0from
add-internal-types-3.0
Nov 20, 2026
Merged

GrahamCampbell merged 1 commit into
3.0from
add-internal-types-3.0

Conversation

@GrahamCampbell

Copy link
Copy Markdown
Member

With PHP 8.0 as the minimum, the types that the private methods of UriTemplate could only state in PHPDoc can be declared. This adds mixed to the nine parameters that were already documented as mixed and a mixed return type to detachValue() and normalizeVariableShape(), which were documented as returning mixed and where every path returns a value or throws, and lets PHP-CS-Fixer drop the PHPDoc tags that became redundant. Nothing changes at run time, and nothing public changes.

@GrahamCampbell
GrahamCampbell marked this pull request as ready for review November 20, 2026 14:03
@GrahamCampbell
GrahamCampbell merged commit f9fc34d into 3.0 Nov 20, 2026
22 checks passed
@GrahamCampbell
GrahamCampbell deleted the add-internal-types-3.0 branch November 20, 2026 14:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant