René's URL Explorer Experiment


Title: Do not flatten template benevolent unions in TypeCombinator::union() by gnutix · Pull Request #5975 · phpstan/phpstan-src · GitHub

Open Graph Title: Do not flatten template benevolent unions in TypeCombinator::union() by gnutix · Pull Request #5975 · phpstan/phpstan-src

X Title: Do not flatten template benevolent unions in TypeCombinator::union() by gnutix · Pull Request #5975 · phpstan/phpstan-src

Description: PHPStan's source code. This is where development happens. Check https://github.com/phpstan/phpstan for the distribution repository. - Do not flatten template benevolent unions in TypeCombinator::union() by gnutix · Pull Request #5975 · phpstan/phpstan-src

Open Graph Description: Closes phpstan/phpstan#7279 Root cause @template K of array-key produces a TemplateBenevolentUnionType (array-key = benevolent int|string). When resolving a PHPDoc union such as K|null (e.g. in a c...

X Description: Closes phpstan/phpstan#7279 Root cause @template K of array-key produces a TemplateBenevolentUnionType (array-key = benevolent int|string). When resolving a PHPDoc union such as K|null (e.g. in a c...

Opengraph URL: https://github.com/phpstan/phpstan-src/pull/5975

X: @github

direct link

Domain: github.com

react-profiling0
react-import-mapreact,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322
route-pattern/_view_fragments/voltron/pull_requests/show/:user_id/:repository/:id/pull_request_layout(.:format)
route-controllervoltron_pull_requests_fragments
route-actionpull_request_layout
fetch-noncev2:0122ca6f-d4bb-1613-7692-5a27e252e308
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-idDA2E:61A3E:59B4D3:7A6A1F:6B0073D3
html-safe-nonce645861a7d0e2e6f48d0f0c8645f426f20553aee44bd64b19063995803821ca18
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJEQTJFOjYxQTNFOjU5QjREMzo3QTZBMUY6NkIwMDczRDMiLCJ2aXNpdG9yX2lkIjoiMzA5MTg1NTgzNTEzNjI5NjUxIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0=
visitor-hmac031867f0927cd2177d6cb89d9916aab77fe842bbb40c87095f138c16430bf367
hovercard-subject-tagpull_request:3980255560
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/pull_requests_fragments/pull_request_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/voltron/pull_requests/show/phpstan/phpstan-src/5975/pull_request_layout
twitter:imagehttps://opengraph.githubassets.com/90c2edacdccf5dbbcbf805bc802766184964f849df6e7e49a2261eca94141f64/phpstan/phpstan-src/pull/5975
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/90c2edacdccf5dbbcbf805bc802766184964f849df6e7e49a2261eca94141f64/phpstan/phpstan-src/pull/5975
og:image:altCloses phpstan/phpstan#7279 Root cause @template K of array-key produces a TemplateBenevolentUnionType (array-key = benevolent int|string). When resolving a PHPDoc union such as K|null (e.g. in a c...
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamegnutix
hostnamegithub.com
expected-hostnamegithub.com
None75c2b65dd205f26961d0c29afed1a8d0bb7cca9f05780571dfd1ef93eb539d16
turbo-cache-controlno-cache
go-importgithub.com/phpstan/phpstan-src git https://github.com/phpstan/phpstan-src.git
octolytics-dimension-user_id16435710
octolytics-dimension-user_loginphpstan
octolytics-dimension-repository_id219334214
octolytics-dimension-repository_nwophpstan/phpstan-src
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id219334214
octolytics-dimension-repository_network_root_nwophpstan/phpstan-src
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release84e563eb4b55f8fa102f325f117533cee9e3df4a
ui-targetfull
theme-color#1e2327
color-schemelight dark
react-app-namepull-requests

Links:

Skip to contenthttps://github.com/phpstan/phpstan-src/pull/5975#start-of-content
https://github.com/
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fphpstan%2Fphpstan-src%2Fpull%2F5975
GitHubRepository hosting, code review, and collaborationhttps://github.com/platform
CopilotAI coding agent for tasks, projects, and automated workhttps://github.com/features/copilot
ActionsCI/CD and automationhttps://github.com/features/actions
Code QualityQuality analysis, fixes, and enforcementhttps://github.com/features/code-quality
CodespacesCloud development environmentshttps://github.com/features/codespaces
Code SecurityVulnerability detection and remediationhttps://github.com/security/advanced-security/code-security
Secret ProtectionSecret scanning and leak preventionhttps://github.com/security/advanced-security/secret-protection
All Featureshttps://github.com/features
Documentationhttps://docs.github.com/en
Traininghttps://learn.github.com/skills
Certificationshttps://learn.github.com/credentials
Build with Copilothttps://github.com/features/ai
Customize Copilothttps://docs.github.com/en/copilot/how-tos/copilot-on-github/customize-copilot/customize-copilot-overview
Integrationshttps://github.com/marketplace
Trending reposhttps://github.com/trending
GitHub Sponsorshttps://github.com/open-source/sponsors
Developer articleshttps://github.com/resources/articles
ChangelogYour source for the latest features, improvements, and fixes across GitHub products, all in one place.https://github.blog/changelog/
Enterpriseshttps://github.com/enterprise
Teamhttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
See all industrieshttps://github.com/solutions/industry
Why GitHubhttps://github.com/why-github
Customer Storieshttps://github.com/customer-stories
Business insightshttps://github.com/solutions/executive-insights
Trust Centerhttps://github.com/trust-center
GitHub Advanced SecurityEnterprise-grade code securityhttps://github.com/security/advanced-security
Copilot for businessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Documentationhttps://docs.github.com/en
Resource centerhttps://github.com/resources
Bloghttps://github.blog/
Events & webinarshttps://github.com/resources/events
Community Forumhttps://github.com/orgs/community/discussions
Customer Storieshttps://github.com/customer-stories
Integrationshttps://github.com/marketplace
Customer supporthttps://help.github.com/
Traininghttps://learn.github.com/skills
GitHub Statushttps://www.githubstatus.com/
Abouthttps://github.com/about
Partnershttps://github.com/partners
Changeloghttps://github.blog/changelog/
GitHub UniverseThe event for developers, by developers — talks, workshops, and what’s next for GitHub.https://githubuniverse.com/
Pricinghttps://github.com/pricing
Sign inhttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fphpstan%2Fphpstan-src%2Fpull%2F5975
Sign uphttps://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fpull_requests_fragments%2Fpull_request_layout&source=header-repo&source_repo=phpstan%2Fphpstan-src
Reloadhttps://github.com/phpstan/phpstan-src/pull/5975
Reloadhttps://github.com/phpstan/phpstan-src/pull/5975
Reloadhttps://github.com/phpstan/phpstan-src/pull/5975
phpstanhttps://github.com/phpstan
phpstan-srchttps://github.com/phpstan/phpstan-src
Codehttps://github.com/phpstan/phpstan-src
Pull requests185 (185)https://github.com/phpstan/phpstan-src/pulls
Actionshttps://github.com/phpstan/phpstan-src/actions
Security and qualityhttps://github.com/phpstan/phpstan-src/security
Insightshttps://github.com/phpstan/phpstan-src/insights
https://github.com/phpstan/phpstan-src
gnutixhttps://github.com/gnutix
phpstan:2.2.xhttps://github.com/phpstan/phpstan-src/tree/2.2.x
gnutix:template-benevolent-unionhttps://github.com/gnutix/phpstan-src/tree/template-benevolent-union
Conversationhttps://github.com/phpstan/phpstan-src/pull/5975
Commits1 (1)https://github.com/phpstan/phpstan-src/pull/5975/commits
Checkshttps://github.com/phpstan/phpstan-src/pull/5975/checks
Files changedhttps://github.com/phpstan/phpstan-src/pull/5975/files
Do not flatten template benevolent unions in TypeCombinator::union()https://github.com/phpstan/phpstan-src/pull/5975#top
gnutixhttps://github.com/gnutix
phpstan:2.2.xhttps://github.com/phpstan/phpstan-src/tree/2.2.x
gnutix:template-benevolent-unionhttps://github.com/gnutix/phpstan-src/tree/template-benevolent-union
https://github.com/gnutix
gnutixhttps://github.com/gnutix
Jul 2, 2026https://github.com/phpstan/phpstan-src/pull/5975#issue-4796763647
Please reload this pagehttps://github.com/phpstan/phpstan-src/pull/5975
phpstan/phpstan#7279https://github.com/phpstan/phpstan/issues/7279
57e3cbfhttps://github.com/phpstan/phpstan-src/commit/57e3cbf90e12b9c23633d7021dde659c5485079d
Claude Codehttps://claude.com/claude-code
Please reload this pagehttps://github.com/phpstan/phpstan-src/pull/5975
https://github.com/gnutix
gnutixhttps://github.com/gnutix
force-pushedhttps://github.com/phpstan/phpstan-src/compare/9854e0f885e6ba3e9ace873b7c6ff794ba85b6e6..4b4d4d5a8f6a059f987d1ab8848e16b546e90ffc
9854e0fhttps://github.com/phpstan/phpstan-src/commit/9854e0f885e6ba3e9ace873b7c6ff794ba85b6e6
4b4d4d5https://github.com/phpstan/phpstan-src/commit/4b4d4d5a8f6a059f987d1ab8848e16b546e90ffc
Compare https://github.com/phpstan/phpstan-src/compare/9854e0f885e6ba3e9ace873b7c6ff794ba85b6e6..4b4d4d5a8f6a059f987d1ab8848e16b546e90ffc
July 2, 2026 17:30https://github.com/phpstan/phpstan-src/pull/5975#event-27492107748
https://github.com/VincentLanglet
VincentLanglethttps://github.com/VincentLanglet
Jul 4, 2026https://github.com/phpstan/phpstan-src/pull/5975#issuecomment-4883223380
@gnutixhttps://github.com/gnutix
Please reload this pagehttps://github.com/phpstan/phpstan-src/pull/5975
https://github.com/gnutix
gnutixhttps://github.com/gnutix
July 4, 2026 19:44https://github.com/phpstan/phpstan-src/pull/5975#event-27562268755
https://github.com/gnutix
gnutixhttps://github.com/gnutix
force-pushedhttps://github.com/phpstan/phpstan-src/compare/4b4d4d5a8f6a059f987d1ab8848e16b546e90ffc..6ccde479b981f19c17d4fea13bfe19ff89c11c55
4b4d4d5https://github.com/phpstan/phpstan-src/commit/4b4d4d5a8f6a059f987d1ab8848e16b546e90ffc
6ccde47https://github.com/phpstan/phpstan-src/commit/6ccde479b981f19c17d4fea13bfe19ff89c11c55
Compare https://github.com/phpstan/phpstan-src/compare/4b4d4d5a8f6a059f987d1ab8848e16b546e90ffc..6ccde479b981f19c17d4fea13bfe19ff89c11c55
July 4, 2026 19:44https://github.com/phpstan/phpstan-src/pull/5975#event-27562269473
https://github.com/gnutix
gnutixhttps://github.com/gnutix
Jul 4, 2026https://github.com/phpstan/phpstan-src/pull/5975#issuecomment-4883651541
@VincentLanglethttps://github.com/VincentLanglet
Please reload this pagehttps://github.com/phpstan/phpstan-src/pull/5975
https://github.com/gnutix
gnutixhttps://github.com/gnutix
force-pushedhttps://github.com/phpstan/phpstan-src/compare/6ccde479b981f19c17d4fea13bfe19ff89c11c55..6c1cfce65551f703a8bfede57dff25bccbb63b3f
6ccde47https://github.com/phpstan/phpstan-src/commit/6ccde479b981f19c17d4fea13bfe19ff89c11c55
6c1cfcehttps://github.com/phpstan/phpstan-src/commit/6c1cfce65551f703a8bfede57dff25bccbb63b3f
Compare https://github.com/phpstan/phpstan-src/compare/6ccde479b981f19c17d4fea13bfe19ff89c11c55..6c1cfce65551f703a8bfede57dff25bccbb63b3f
July 4, 2026 20:11https://github.com/phpstan/phpstan-src/pull/5975#event-27562614340
https://github.com/staabm
staabmhttps://github.com/staabm
Jul 5, 2026 https://github.com/phpstan/phpstan-src/pull/5975#pullrequestreview-4630837086
View reviewed changes https://github.com/phpstan/phpstan-src/pull/5975/files
tests/PHPStan/Analyser/nsrt/bug-7279.phphttps://github.com/phpstan/phpstan-src/pull/5975/files#diff-5386c0d740d715639db490563201c016792bca6d725843cd79fd0ed16f9fa374
Please reload this pagehttps://github.com/phpstan/phpstan-src/pull/5975
https://github.com/gnutix
gnutixhttps://github.com/gnutix
force-pushedhttps://github.com/phpstan/phpstan-src/compare/6c1cfce65551f703a8bfede57dff25bccbb63b3f..a5bd8b488c9609dcda74813fa93bc634c4ec5a06
6c1cfcehttps://github.com/phpstan/phpstan-src/commit/6c1cfce65551f703a8bfede57dff25bccbb63b3f
a5bd8b4https://github.com/phpstan/phpstan-src/commit/a5bd8b488c9609dcda74813fa93bc634c4ec5a06
Compare https://github.com/phpstan/phpstan-src/compare/6c1cfce65551f703a8bfede57dff25bccbb63b3f..a5bd8b488c9609dcda74813fa93bc634c4ec5a06
July 5, 2026 07:44https://github.com/phpstan/phpstan-src/pull/5975#event-27569914360
https://github.com/staabm
staabmhttps://github.com/staabm
Jul 5, 2026https://github.com/phpstan/phpstan-src/pull/5975#issuecomment-4885323138
Please reload this pagehttps://github.com/phpstan/phpstan-src/pull/5975
Please reload this pagehttps://github.com/phpstan/phpstan-src/pull/5975
https://github.com/gnutix
gnutixhttps://github.com/gnutix
force-pushedhttps://github.com/phpstan/phpstan-src/compare/a5bd8b488c9609dcda74813fa93bc634c4ec5a06..2974f04b8aa9c164fd11c6442d2a7579f8f9f5c8
a5bd8b4https://github.com/phpstan/phpstan-src/commit/a5bd8b488c9609dcda74813fa93bc634c4ec5a06
2974f04https://github.com/phpstan/phpstan-src/commit/2974f04b8aa9c164fd11c6442d2a7579f8f9f5c8
Compare https://github.com/phpstan/phpstan-src/compare/a5bd8b488c9609dcda74813fa93bc634c4ec5a06..2974f04b8aa9c164fd11c6442d2a7579f8f9f5c8
July 5, 2026 08:20https://github.com/phpstan/phpstan-src/pull/5975#event-27570345840
https://github.com/gnutix
https://github.com/claude
Do not flatten template benevolent unions in TypeCombinator::union()https://github.com/phpstan/phpstan-src/pull/5975/commits/4a860bb1023a23032ea4064d9d685ff926aff296
4a860bbhttps://github.com/phpstan/phpstan-src/pull/5975/commits/4a860bb1023a23032ea4064d9d685ff926aff296
57e3cbfhttps://github.com/gnutix/phpstan-src/commit/57e3cbf90e12b9c23633d7021dde659c5485079d
https://github.com/gnutix
gnutixhttps://github.com/gnutix
force-pushedhttps://github.com/phpstan/phpstan-src/compare/2974f04b8aa9c164fd11c6442d2a7579f8f9f5c8..4a860bb1023a23032ea4064d9d685ff926aff296
2974f04https://github.com/phpstan/phpstan-src/commit/2974f04b8aa9c164fd11c6442d2a7579f8f9f5c8
4a860bbhttps://github.com/phpstan/phpstan-src/commit/4a860bb1023a23032ea4064d9d685ff926aff296
Compare https://github.com/phpstan/phpstan-src/compare/2974f04b8aa9c164fd11c6442d2a7579f8f9f5c8..4a860bb1023a23032ea4064d9d685ff926aff296
July 5, 2026 11:39https://github.com/phpstan/phpstan-src/pull/5975#event-27572645794
https://github.com/gnutix
gnutixhttps://github.com/gnutix
Jul 5, 2026https://github.com/phpstan/phpstan-src/pull/5975#issuecomment-4885924224
Please reload this pagehttps://github.com/phpstan/phpstan-src/pull/5975
https://github.com/staabm
staabmhttps://github.com/staabm
Jul 5, 2026https://github.com/phpstan/phpstan-src/pull/5975#issuecomment-4886196006
Please reload this pagehttps://github.com/phpstan/phpstan-src/pull/5975
Please reload this pagehttps://github.com/phpstan/phpstan-src/pull/5975
https://github.com/gnutix
gnutixhttps://github.com/gnutix
Jul 5, 2026https://github.com/phpstan/phpstan-src/pull/5975#issuecomment-4887302576
Please reload this pagehttps://github.com/phpstan/phpstan-src/pull/5975
Please reload this pagehttps://github.com/phpstan/phpstan-src/pull/5975
https://github.com/VincentLanglet
VincentLanglethttps://github.com/VincentLanglet
Jul 5, 2026https://github.com/phpstan/phpstan-src/pull/5975#issuecomment-4887469841
Please reload this pagehttps://github.com/phpstan/phpstan-src/pull/5975
https://github.com/gnutix
gnutixhttps://github.com/gnutix
Jul 6, 2026https://github.com/phpstan/phpstan-src/pull/5975#issuecomment-4889909845
Please reload this pagehttps://github.com/phpstan/phpstan-src/pull/5975
Please reload this pagehttps://github.com/phpstan/phpstan-src/pull/5975
https://github.com/staabm
staabmhttps://github.com/staabm
Sep 9, 2026https://github.com/phpstan/phpstan-src/pull/5975#issuecomment-5603248168
#6376https://github.com/phpstan/phpstan-src/pull/6376
Please reload this pagehttps://github.com/phpstan/phpstan-src/pull/5975
https://github.com/staabm
staabmhttps://github.com/staabm
Sep 9, 2026https://github.com/phpstan/phpstan-src/pull/5975#event-30834590327
https://github.com/gnutix
gnutixhttps://github.com/gnutix
Sep 9, 2026https://github.com/phpstan/phpstan-src/pull/5975#issuecomment-5605656648
Please reload this pagehttps://github.com/phpstan/phpstan-src/pull/5975
#6376https://github.com/phpstan/phpstan-src/pull/6376
phpstan/phpstan#7279https://github.com/phpstan/phpstan/issues/7279
@calebdwhttps://github.com/calebdw
Please reload this pagehttps://github.com/phpstan/phpstan-src/pull/5975
https://github.co/hiddenchars
https://github.com/phpstan/phpstan-src/pull/{{ revealButtonHref }}
Sign up for freehttps://github.com/join?source=comment-repo
Sign in to commenthttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fphpstan%2Fphpstan-src%2Fpull%2F5975
https://github.com/staabm
staabm https://github.com/staabm
https://github.com/phpstan/phpstan-src/pull/5975/files/6c1cfce65551f703a8bfede57dff25bccbb63b3f
Please reload this pagehttps://github.com/phpstan/phpstan-src/pull/5975
Type inferring is incorrect on @template K of array-key, yet it is correct for (almost) the same code with @template T https://github.com/phpstan/phpstan/issues/7279
Please reload this pagehttps://github.com/phpstan/phpstan-src/pull/5975
https://github.com/gnutix
https://github.com/VincentLanglet
https://github.com/staabm
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.