Bug 213638

Summary: [JSC] Add Intl.Segmenter
Product: WebKit Reporter: Yusuke Suzuki <ysuzuki>
Component: JavaScriptCoreAssignee: Yusuke Suzuki <ysuzuki>
Status: RESOLVED FIXED    
Severity: Normal CC: annulen, benjamin, cdumez, cmarcelo, ews-watchlist, gyuyoung.kim, keith_miller, mark.lam, msaboff, ross.kirsling, ryuan.choi, saam, sergio, tzagallo, webkit-bug-importer
Priority: P2 Keywords: InRadar
Version: WebKit Nightly Build   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 213425    
Attachments:
Description Flags
Patch
none
Patch
ross.kirsling: review+
Rebaseline, test262
none
Rebaseline + update
none
Patch none

Yusuke Suzuki
Reported 2020-06-25 21:18:05 PDT
...
Attachments
Patch (122.34 KB, patch)
2020-07-21 19:51 PDT, Yusuke Suzuki
no flags
Patch (122.70 KB, patch)
2020-07-21 19:57 PDT, Yusuke Suzuki
ross.kirsling: review+
Rebaseline, test262 (113.15 KB, patch)
2020-07-25 22:44 PDT, Yusuke Suzuki
no flags
Rebaseline + update (110.70 KB, patch)
2020-07-25 22:52 PDT, Yusuke Suzuki
no flags
Patch (109.74 KB, patch)
2020-07-31 23:21 PDT, Yusuke Suzuki
no flags
Yusuke Suzuki
Comment 1 2020-07-21 19:51:01 PDT
Yusuke Suzuki
Comment 2 2020-07-21 19:57:50 PDT
Ross Kirsling
Comment 3 2020-07-22 12:00:51 PDT
Comment on attachment 404896 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=404896&action=review r=me. I'm sad that we don't have test262 tests yet, but it's behind a flag, so we can keep tweaking things. > Source/JavaScriptCore/runtime/IntlSegmenter.cpp:180 > + result->putDirect(vm, vm.propertyNames->isWordLike, jsBoolean(!(ruleStatus >= UBRK_WORD_NONE && ruleStatus <= UBRK_WORD_NONE_LIMIT))); Seems like DeMorgan's rule wouldn't make this less clear? jsBoolean(ruleStatus < UBRK_WORD_NONE || ruleStatus > UBRK_WORD_NONE_LIMIT)
Yusuke Suzuki
Comment 4 2020-07-22 13:14:00 PDT
Comment on attachment 404896 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=404896&action=review Thanks! >> Source/JavaScriptCore/runtime/IntlSegmenter.cpp:180 >> + result->putDirect(vm, vm.propertyNames->isWordLike, jsBoolean(!(ruleStatus >= UBRK_WORD_NONE && ruleStatus <= UBRK_WORD_NONE_LIMIT))); > > Seems like DeMorgan's rule wouldn't make this less clear? > jsBoolean(ruleStatus < UBRK_WORD_NONE || ruleStatus > UBRK_WORD_NONE_LIMIT) I think that the current one is clear than < || > form since it is saying rulesStatus is not in this range.
Yusuke Suzuki
Comment 5 2020-07-25 22:44:34 PDT
Created attachment 405242 [details] Rebaseline, test262
Yusuke Suzuki
Comment 6 2020-07-25 22:46:48 PDT
Yusuke Suzuki
Comment 7 2020-07-25 22:47:48 PDT
Comment on attachment 405242 [details] Rebaseline, test262 View in context: https://bugs.webkit.org/attachment.cgi?id=405242&action=review > JSTests/test262/expectations.yaml:1688 > +test/intl402/Segmenter/prototype/segment/segment-grapheme.js: > + default: 'Test262Error: Expected SameValue(«0», «undefined») to be true' > + strict mode: 'Test262Error: Expected SameValue(«0», «undefined») to be true' > +test/intl402/Segmenter/prototype/segment/segment-sentence.js: > + default: 'Test262Error: Expected SameValue(«0», «undefined») to be true' > + strict mode: 'Test262Error: Expected SameValue(«0», «undefined») to be true' > +test/intl402/Segmenter/prototype/segment/segment-tostring.js: > + default: 'Test262Error: Expected segment "undefined", found "undefined" for arguments Expected SameValue(«undefined», «undefined») to be true' > + strict mode: 'Test262Error: Expected segment "undefined", found "undefined" for arguments Expected SameValue(«undefined», «undefined») to be true' > +test/intl402/Segmenter/prototype/segment/segment-word.js: > + default: 'Test262Error: Expected SameValue(«0», «undefined») to be true' > + strict mode: 'Test262Error: Expected SameValue(«0», «undefined») to be true' test262 will be fixed in https://github.com/tc39/test262/pull/2714
Yusuke Suzuki
Comment 8 2020-07-25 22:52:48 PDT
Created attachment 405243 [details] Rebaseline + update
Yusuke Suzuki
Comment 9 2020-07-31 23:21:53 PDT
Created attachment 405769 [details] Patch Rebaseline
Yusuke Suzuki
Comment 10 2020-08-22 12:22:30 PDT
Radar WebKit Bug Importer
Comment 11 2020-08-22 12:23:24 PDT
Note You need to log in before you can comment on or make changes to this bug.