The layout test fails on macOS Mojave.
Created attachment 342239 [details] WIP
Created attachment 342244 [details] Fixes the bug
Wow, that’s one crazy bug! R=me, unofficially.
Comment on attachment 342244 [details] Fixes the bug View in context: https://bugs.webkit.org/attachment.cgi?id=342244&action=review > Source/WebCore/ChangeLog:32 > + wordBreakIteratorForMaxOffsetBoundary with visible position at offset 0 of "world", it thiss line and return nullptr. It should read "it skip this line and return nullptr."
Great work! Is it possible to add a test that verifies this bug fix in a more straightforward manner, and maybe even extends testing in similar edge cases? Seems like we got lucky that a mostly unrelated test caught this.
(In reply to Alexey Proskuryakov from comment #5) > Great work! > > Is it possible to add a test that verifies this bug fix in a more > straightforward manner, and maybe even extends testing in similar edge > cases? Seems like we got lucky that a mostly unrelated test caught this. I wouldn't say we got lucky since the failing test basically tests every word movement across divs with variety position values in order to catch exactly like the bug like this. Having said that, I can add a new test which tests this exact failure although it would still require macOS Mojave to test it. I'm not certain adding a new mostly redundant test like that is useful though...
Sounds like it would not be very useful given that.
(In reply to Alexey Proskuryakov from comment #7) > Sounds like it would not be very useful given that. Okay. I'll land the patch as is then.
Committed r232635: <https://trac.webkit.org/changeset/232635>
<rdar://problem/40948830>