• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: NSCalendar and NSDates prior to October 15, 1582
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: NSCalendar and NSDates prior to October 15, 1582


  • Subject: Re: NSCalendar and NSDates prior to October 15, 1582
  • From: Steve Mykytyn <email@hidden>
  • Date: Thu, 12 Feb 2015 11:38:13 -0800

Bug report submitted.

It also turns out there are lots of interesting failures with NSDate,
NSDateFormatter, NSCalendar, NSNumberFormatter, etc. if you go sufficiently
far from the present -- 144,684 AD and 5,828,963 AD are the magic numbers
in the positive direction.

Blog post here:
http://359north.com/blog/2015/02/08/the-limits-of-nsdate-and-friends/

iOS Project here: https://github.com/359north/nsdate-limits

NSDate is precise to the second out to around 285,426,782 AD, but some of
its compatriots let it down.

On Thu, Feb 5, 2015 at 11:34 AM, Greg Parker <email@hidden> wrote:

>
> > On 2015 Jan 30, at 12:32, Steve Mykytyn wrote:
> >
> > The documentation for the Date and Time Programming Guide for iOS does
> not seem to be telling the truth, or perhaps I'm doing something wrong.
>
> Please file a bug report.
>
> > On Feb 5, 2015, at 6:56 AM, Jeffrey Oleander <email@hidden> wrote:
> >
> > Some countries did not adopt the Gregorian adjustment until the 1750s,
> and others much later than that (Russia partially converted in 1700 but not
> completely until 1922, Turkey in 1926).  Anyway, it's not something you can
> do a neat mathematical conversion on and have it work "perfectly"
> everywhere and for every date.   What of those of us who have to deal with
> dates going back to e.g. 1200BCE?
>
> The Date and Time Programming Guide mentions that issue too.
>
> "Some countries adopted the Gregorian calendar at various later times.
> Nevertheless, for consistency the change is modeled at the same time
> regardless of locale. If you need absolute historical accuracy for a
> particular locale…"
>
>
> --
> Greg Parker     email@hidden     Runtime Wrangler
>
>
>
_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden


References: 
 >Re: NSCalendar and NSDates prior to October 15, 1582 (From: Jeffrey Oleander <email@hidden>)
 >Re: NSCalendar and NSDates prior to October 15, 1582 (From: Greg Parker <email@hidden>)

  • Prev by Date: Re: All buttons lost focus ring on Yosemite
  • Next by Date: Re: Connecting a button to MyView zeros integers
  • Previous by thread: Re: NSCalendar and NSDates prior to October 15, 1582
  • Next by thread: -windowdidLoad
  • Index(es):
    • Date
    • Thread