LibUnicode: Tweak the definition of the plurality "many"

As noted at the top of this method, this is a naive implementation of
the Unicode plurality specification. But for now, we should tweak the
defintion of "many" to be "more than 2" (which is what I had in mind
when I wrote this, but forgot about fractions).
This commit is contained in:
Timothy Flynn 2021-11-16 16:56:26 -05:00 committed by Linus Groh
parent c24a350a18
commit 80493908d3
Notes: sideshowbarker 2024-07-18 01:04:06 +09:00

View file

@ -995,7 +995,7 @@ Optional<NumberFormat> select_pattern_with_plurality(Vector<NumberFormat> const&
} else if (number == 2) {
if (auto patterns = find_plurality(NumberFormat::Plurality::Two); patterns.has_value())
return patterns;
} else {
} else if (number > 2) {
if (auto patterns = find_plurality(NumberFormat::Plurality::Many); patterns.has_value())
return patterns;
}