Skip to content

Freeze trim characters ahead of PHP 8.6#121

Merged
GrahamCampbell merged 1 commit into
masterfrom
trim-characters
Jul 6, 2026
Merged

Freeze trim characters ahead of PHP 8.6#121
GrahamCampbell merged 1 commit into
masterfrom
trim-characters

Conversation

@GrahamCampbell

Copy link
Copy Markdown
Collaborator

PHP 8.6 adds the form feed character to the default $characters set of trim, so the expression-argument normalization in the shipped bin/jp.php binary, the one call in this package relying on the default, would change behavior there. This change passes the pre-8.6 set explicitly, keeping behavior identical on every PHP version. An audit of the rest of the package found nothing else to fix: the only other trim call already passes an explicit character list, and the only two preg_match calls are fail-closed validations that already carry the D modifier.

@GrahamCampbell GrahamCampbell merged commit aa13a7b into master Jul 6, 2026
40 checks passed
@GrahamCampbell GrahamCampbell deleted the trim-characters branch July 6, 2026 18:55
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