-
Notifications
You must be signed in to change notification settings - Fork 185
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
LocalePreferences: bikeshed #5786
Comments
#[non_exhaustive]
pub struct ListFormatterPreferences {
pub locale_prefs: LocalePreferences,
}
Conclusion:
LGTM: @sffc @zbraniecki @robertbastian |
A quick attempt to do this doesn't work; the |
If we're making this private, we should probably document that these preferences are here, and have some form of way of setting them from the locale? |
Now that we have #[allow(clippy::exhaustive_structs)] // this type is stable
#[derive(Debug, Clone, Copy, PartialEq, Eq, Hash)]
pub struct LocalePreferences |
@sffc Should I close #5955 then, or do you think this change is still valuable? Overall having these types have all-public fields does feel nice from the POV of documentation, at least. When I made
This should be fixed by #5785 , yes? I can work on that next. |
It's a bit confusing since these were both discussed on the same day, but given that we decided to make the fields of LocalePreferences be private, I think on this issue I might be of the opinion that |
@zbraniecki @robertbastian what do you feel about the above proposal? |
I'm ok keeping it public |
Current plan: rename the field to |
LocalePreferences
landed in #5729. Two things I want to decide about it before it gets shipped:PreferencesLocale
is a better name, but would also be happy with naming it "what it is" such asLanguageIdentifierWithRegionExtensions
, for example.Public fields. I don't consider the design of this type 100% finalized. The CLDR spec it is implementing is still a concept, not yet landed in UTS 35. I would prefer it to have private fields.EDIT: Moved to Discuss: Should LocalePreferences have public fields #5785@zbraniecki @robertbastian
The text was updated successfully, but these errors were encountered: