Smartling / ios-i18n

The ios-i18n library provides seamless integration of plurals into iOS 6 apps.
http://www.smartling.com
Apache License 2.0
205 stars 41 forks source link

zero is not permitted as pluralized form for English #21

Open DawnWright opened 8 years ago

DawnWright commented 8 years ago

We require the ability to add a {zero} pluralized form for English, which is distinct from {other}. Smartling's library only allows the required forms to be specified ({one} and {other}, for English).

The CLDR encourages use of such optional forms, for more natural language:

The minimal pairs are those that are required for correct grammar. So because 0 and 1 don't have to form a minimal pair (it is ok—even though often not optimal—to say "0 people") , 0 doesn't establish a separate category. However, implementations are encouraged to provide the ability to have special plural messages for 0 in particular, so that more natural language can be used:

  • None of your friends are online. rather than
  • You have 0 friends online.

http://cldr.unicode.org/index/cldr-spec/plural-rules

But Smartling's library does not support this CLDR recommendation.

By not supporting this, apps are forced to either not use the Smartling library, or special-case the zero form in code, which in turn will cause the zero form to break in languages where zero is required.

I noticed this issue was discussed a year and a half ago here, and would like to see this issue revisited.

vitalybaev commented 8 years ago

As I tested, zero rule doesn't work in ru_RU locale too.

DawnWright commented 8 years ago

The problem exists for all languages where {zero} is not a required form. This indeed includes Russian, per http://www.unicode.org/cldr/charts/latest/supplemental/language_plural_rules.html

asaxesmartling commented 8 years ago

We're reviewing now how we could support the {zero} form throughout the Smartling platform including the iOS i18n library. No scheduled release date yet.

DawnWright commented 8 years ago

Great, thank you for looking at this.