jwodder / julian-rs

Convert between Julian day numbers and Julian & Gregorian calendars
MIT License
3 stars 1 forks source link

The calender type seems unable to represent some real Julian -> Gregorian calenders in history #77

Closed VorpalBlade closed 7 months ago

VorpalBlade commented 7 months ago

Feel free to close this as out of scope if you think it is! I don't have an actual use for it, it is just pedantry I guess as I came across your crate.

I was looking at the API of your Calender type and noticed it only seems to support:

Unfortunately not all countries had such an easy transition. I thought it was just my own native country (Sweden) that screwed this up (see https://en.wikipedia.org/wiki/Swedish_calendar for some date keeping humour/horror) but apparently there were many more.

If this is out of scope, I am curious if you know of a rust library that can handle this mess (as well as other global calendars, outside of Europe). Especially since I'm pretty sure some dates will be ambiguous without reference to what calendar they are in (and possibly even which country and province).

jwodder commented 7 months ago

I'm aware of Sweden and its messy calendar, but I consider calendars other than the cases you've listed as out of scope, and I do not ever foresee supporting others. Unfortunately, I know of no library (Rust or otherwise) that does support such irregularities.

VorpalBlade commented 7 months ago

Closing this issue then