docs(changelog): correct the _hasExplicitCrossWidth claim in the #180 entry - #183
Conversation
…entry
The entry said the trailing newline caused a "miss" at that site whose cost was
a redundant wrapper. There was no miss. `_hasExplicitCrossWidth` matches with
`startsWith('w-')` rather than equality, and `'w-24\n'.startsWith('w-')` is
true, so a newline never hid an explicit width from it.
That also corrects the reasoning, not just the wording. The test written for
that site passed before the fix because the predicate already worked, not
because the consequence was unobservable, which is what the entry implied and
what I had concluded.
CodeRabbit raised this on #180 and I read its finding as claiming the entry
asserted a behavioural fix, which it did not, so the thread closed with the
mechanism agreed and this sentence left standing. Correcting it before it ships
in the 1.4.1 release notes.
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
|
Note Kodizm (AI-generated). May contain mistakes; verify before acting. The correction replaces one overreaching claim with another: Major
Ported the pre-fix predicate verbatim and ran it: So the accurate statement is narrower than either version: the predicate tolerated a trailing newline, and still missed a Minor
TestsNo test change, and none is needed for a prose edit. The rest of the entry checks out: three pre-fix sites used Checks I ran
|
What
One sentence in the
[Unreleased]entry for #180. It said the trailing newline caused a "miss" at_hasExplicitCrossWidthwhose cost was a redundant wrapper. There was no miss.Why
That predicate matches with a prefix test, not equality:
'w-24\n'.startsWith('w-')istrue, so a token ending a line was always detected there. The newline only defeated the two sites that compare for equality,_selfWrapsInFlex(token == 'grow', and the^flex-[0-9]+$regex) and_hasShrinkZero(token == 'shrink-0'), which are the two failures #180 reproduced and pinned.This is a correction of the reasoning and not only the wording. I had explained the test I wrote for that site passing on
masteras the consequence being unobservable, with the child's ownw-24winning inside the stretch wrapper. The real reason is simpler: the predicate already worked. The change at that site is tokenization consistency across all five scans and nothing more, and that is now what the entry says.CodeRabbit raised this on #180. I read its finding as claiming the entry asserted a behavioural fix, which the entry did not, so the thread closed with the mechanism agreed between us and this sentence left standing. It is still wrong, and it would otherwise ship verbatim in the next release notes, which is why it is worth a PR of its own rather than a note in a future one.
Scope
CHANGELOG.mdonly, one sentence, inside the unreleased section. No source change, so nothing inlib/moves and the #180 fix itself is untouched.python3 tool/check-docs.py: 0 issues across 72 doc pages.