rocket_i18n icon indicating copy to clipboard operation
rocket_i18n copied to clipboard

Make sure languages "with two parts" are handled correctly

Open elegaanz opened this issue 6 years ago • 3 comments

For instance en-US or pt-BR

elegaanz avatar May 12 '19 19:05 elegaanz

I think they should be because of https://github.com/Plume-org/rocket_i18n/blob/master/src/with_rocket.rs#L24 and https://github.com/Plume-org/rocket_i18n/blob/master/src/with_actix.rs#L50 ? Or did you mean somewhere else?

trinity-1686a avatar May 12 '19 19:05 trinity-1686a

Yes, but my concern was more about making sure they are working with gettext-macros too, and that the two-parts version is correctly used when needed if the one-part version is also available (not sure if I'm clear, sorry).

elegaanz avatar May 12 '19 19:05 elegaanz

If I'm reading that code right, the locale part (so -Lo out of ln-Lo) is simply ignored?

I believe it is very important to support this because of the Chinese language. The locales "Chinese (Traditional)" and "Chinese (Simplified)" are quite different, but share the zh language prefix.

Valodim avatar Nov 14 '19 12:11 Valodim