Language: ReflectionType::__toString DNF parens and ?T for T|null (#23065)#23090
Merged
Conversation
…3065) Match php-src zend_type_to_string: wrap intersection groups in unions and normalize single-named |null unions to ?T for ReflectionType string casts. Co-authored-by: Cursor <cursoragent@cursor.com>
This was referenced Jul 25, 2026
Closed
PurHur
added a commit
that referenced
this pull request
Jul 25, 2026
) (#23096) Pillar 1: 4f-m drifted again (95e2817e… vs live 92251643…) after Reflection private(set)/DNF merges; inventory construct flags also went stale. Stamp with BOOTSTRAP_GEN0_ALLOW_UNVERIFIED_STAMP=1; regenerate docs/bootstrap-inventory.md. Honest verified-fresh rebuild remains #22717. Co-authored-by: PurHur <PurHur@users.noreply.github.com> Co-authored-by: Cursor <cursoragent@cursor.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
zend_type_to_string/ReflectionType::__toStringfor DNF unions (parentheses around intersection groups) and single-named|null→?T.lib/VM/ReflectionTypeSupport.php— no newruntime/*.c..phpt+ repro; JIT umbrella skip (MCJIT lacksReflectionFunction::getParameters).Closes #23065
php-src reference
ext/reflection/php_reflection.c— ReflectionType stringificationzend_type_to_string) for DNF parens /?TPHP implementation
lib/VM/ReflectionTypeSupport.php—cfgTypeStringDNF parens;buildTypeObjectstorescfgTypeStringForDumpfor unionsTest plan
php bin/vm.php test/repro/issue_23065_reflection_type_tostring.phpdiffmatch./script/phpunit.sh --filter 'ReflectionTypesTest|reflection_type_tostring_dnf_null'→ OK (5 tests)Verification
Trust snapshot (#10533)
release-readiness --jsonnorth-star5-fast: fail (gen-0 manifest/driver mismatch Self-host M5: bootstrap-inventory argv driver size floor — grow beyond 451KB stub #8713 / Gen-1+ #1492: committed gen-0 seed cannot be rebuilt — refresh OOMs at 48 GiB, 44 restamps since the blob last changed (script/bootstrap-refresh-gen0-sidecar.sh) #22642) — unrelated; open PRs Trust: restamp gen-0 fingerprint after #23078–#23084 drift (#10533) #23085 / Bootstrap: unblock gen-0 spine refresh — docblock, ghost require, exclusive launcher (#22642) #22717user_release_ready: no (same gate)Made with Cursor