-
Notifications
You must be signed in to change notification settings - Fork 167
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
Now might be a good time to figure out off-the-shelf calendar sets in DateTimeFormatter #4889
Comments
I think this is a good idea and is a great example of why the neo model works much better overall. We may need to eventually figure out what counts as extended but for now "Japanext + community calendars" seems fine. |
Conclusion: In 2.0, remove JapaneseExtended from AnyCalendar and DateTimeFormatter bounds LGTM: @sffc @robertbastian @Manishearth thoughts? |
I'm fine with this. Should we also consider removing any of the Islamic ones? I'm not sure which ones are "major" or in active civil use. |
The CLDR data has each calendar except Julian (and Japanese Extended) listed in at least one locale: <calendarPreferenceData>
<calendarPreference territories="001" ordering="gregorian"/>
<calendarPreference territories="BD DJ DZ EH ER ID IQ JO KM LB LY MA MR MY NE OM PK PS SD SY TD TN YE" ordering="gregorian islamic islamic-civil islamic-tbla"/>
<calendarPreference territories="AL AZ MV TJ TM TR UZ XK" ordering="gregorian islamic-civil islamic-tbla"/>
<calendarPreference territories="AE BH KW QA" ordering="gregorian islamic-umalqura islamic islamic-civil islamic-tbla"/>
<calendarPreference territories="AF IR" ordering="persian gregorian islamic islamic-civil islamic-tbla"/>
<calendarPreference territories="CN CX HK MO SG" ordering="gregorian chinese"/>
<calendarPreference territories="EG" ordering="gregorian coptic islamic islamic-civil islamic-tbla"/>
<calendarPreference territories="ET" ordering="gregorian ethiopic"/>
<calendarPreference territories="IL" ordering="gregorian hebrew islamic islamic-civil islamic-tbla"/>
<calendarPreference territories="IN" ordering="gregorian indian"/>
<calendarPreference territories="JP" ordering="gregorian japanese"/>
<calendarPreference territories="KR" ordering="gregorian dangi"/>
<calendarPreference territories="SA" ordering="islamic-umalqura gregorian islamic islamic-rgsa"/>
<calendarPreference territories="TH" ordering="buddhist gregorian"/>
<calendarPreference territories="TW" ordering="gregorian roc chinese"/>
</calendarPreferenceData> That said, I don't have a very great sense of which Hijri calendars are needed in which contexts. For example, would it be acceptable if we included |
Yeah that's what I'm trying to figure out; it's unclear which ones are actually in use. |
I would keep all "Islamic"s. I know for a fact that Saudi Arabia uses islamic-umalqura, that Iran uses islamic observational, and that some Arab countries use the tabular and civil calendars. All four are needed. |
We currently have only two modes: one calendar or all calendars. The problem with all-calendars is that it includes JapaneseExtended, which we made separate specifically because we want it to be excluded by default, and it would also include any potential non-CLDR calendars that we get from third party contributors.
While I'm in the middle of the NeoDateFormatter restructuring, it would not be hard for me to add multiple constructors:
NeoFormatter::try_new
for the recommended calendar setNeoFormatter::try_new_extended
for the full calendar setThe good news is that with fewer formatter types, we don't need to generate lots of contructors on lots of types. We would need to add these on only one type,
NeoFormatter
.Thoughts?
@Manishearth @zbraniecki
The text was updated successfully, but these errors were encountered: