Skip to content

Commit beafd63

Browse files
committed
docs(changelog): clarify MethodToMethodWithCheckRector BC-wrap edge case
The bullet under [Unreleased] / ### Changed previously claimed the BC wrap "addresses the underlying concern" of the dropped maybe-path TODO comment in all cases. That's only true for configurations with introducedVersion >= 10.0.0 — pre-10.0 entries (urlInfo, getLowercaseLabel, clearCsrfTokenSeed) fall outside the BC-wrap gate and rewrite a maybe-typed receiver unconditionally. Contrib audit (api.tresbien.tech) found zero live callers of those three methods on receivers PHPStan cannot resolve, so the residual risk is theoretical. Updates the CHANGELOG bullet to acknowledge this explicitly rather than overclaim safety.
1 parent 190b583 commit beafd63

1 file changed

Lines changed: 10 additions & 3 deletions

File tree

CHANGELOG.md

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -396,9 +396,16 @@ release-by-release.
396396
- `MethodToMethodWithCheckRector` no longer attaches a "please confirm the
397397
receiver type" TODO comment for the `maybe` type-inference case. The
398398
comment-on-parent-statement mechanism relied on parent-node tracking that
399-
Rector 2.x removed; the BC wrap makes both code paths runtime-safe by
400-
selecting the right call based on `\Drupal::VERSION`, which addresses the
401-
underlying concern.
399+
Rector 2.x removed. For configurations whose `introducedVersion ≥ 10.0.0`,
400+
the BC wrap selects the right call at runtime via `\Drupal::VERSION` and
401+
fully addresses the underlying concern. Configurations with an older
402+
introduced version (e.g. `urlInfo``toUrl` @ 8.0.0,
403+
`getLowercaseLabel``getSingularLabel` @ 8.8.0,
404+
`clearCsrfTokenSeed``stampNew` @ 9.2.0) fall outside the BC-wrap gate
405+
and rewrite unconditionally on a `maybe`-typed receiver. Contrib audit
406+
(api.tresbien.tech, 2026-05-28) found zero live callers of those three
407+
methods on receivers PHPStan cannot resolve to a concrete type, so the
408+
residual risk is theoretical.
402409

403410
## [1.0.0-beta1] — 2026-05-25
404411

0 commit comments

Comments
 (0)