News for hackers. Stuff that matters.
Re:Ruby's Date/DateTime classes rewritten in C.. 20-200x per... by j-g-faustus on Monday August 23, 2010 @12:43PM (#1627225)
I implemented just the subset of the Date API I needed for the application, so it didn't do conversions to other calendar formats (Julian/ordinal/commercial etc.).

I don't know why their version is so slow, I can only imagine that the conversion to Astronomical Julian Day (the Ruby Date internal representation) is expensive, inefficient or both.

I used year/month/day ints as internal representation, which was fast for my use cases (parse date string, format date string, compare two dates).

There are no comments on this comment yet.