mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-07 18:04:46 +00:00
f8152b2b24
The motivation of this patch is to remove rarely used API in WordBreaker. WordBreaker::BreakInBetween() is used only in nsFind::BreakInBetween() in production, and it can be replaced by Next(). If the user wants to know whether there is a word break between two strings such as the use cases in gtest, joining the two strings and passing the result to Next() is the preferred way. Note: I delete the buggy forward word search algorithm in TestFindWordBreakFromPosition() because from the test expectations, it doesn't expect to continue the search in previous fragments. Also, the buggy part comes from the following code, which had undefined behavior before Part 4, and does nothing after Part 4. ``` wbk->FindWord(prevFragText.get(), prevFragText.Length(), prevFragText.Length()); ``` Differential Revision: https://phabricator.services.mozilla.com/D125151 |
||
---|---|---|
.. | ||
crashtests | ||
gtest | ||
tools | ||
jisx4051class.h | ||
jisx4051pairtable.txt | ||
LineBreaker.cpp | ||
LineBreaker.h | ||
moz.build | ||
nsCarbonBreaker.cpp | ||
nsComplexBreaker.h | ||
nsLWBrkCIID.h | ||
nsPangoBreaker.cpp | ||
nsRuleBreaker.cpp | ||
nsUniscribeBreaker.cpp | ||
rulebrk.c | ||
rulebrk.h | ||
th_char.h | ||
WordBreaker.cpp | ||
WordBreaker.h |