develooper Front page | perl.perl6.language | Postings from April 2010

Re: r30398 - docs/Perl6/Spec/S32-setting-library

From:
Dave Rolsky
Date:
April 20, 2010 07:59
Subject:
Re: r30398 - docs/Perl6/Spec/S32-setting-library
Message ID:
alpine.DEB.0.9999.1004200956560.28946@urth.org
On Fri, 16 Apr 2010, pugs-commits@feather.perl6.nl wrote:

> +=head2 Semi-internal methods
> +
> +[This section is severely conjectural]
> +
> +For efficient implementation of arithmetics on C<Date> objects, two more
> +methods are exposed:
> +
> +    $d.daycount
> +    Date.new-from-daycount(Int $daycount)

I'd _really_ like to see this be based on Rata Die, which is January 1, 
0001. See http://en.wikipedia.org/wiki/Rata_Die

This epoch value is used as the basis for many calendrical calculations in 
the Calendarical Calculations book, and has in turn been used as the 
method for calendar conversion in the Perl 5 DateTime sweet.

Exposing this value explicitly (rata-die-day-count) would be a wise 
decision, IMO.

Also, "day-count", not "daycount" ;)


-dave

/*============================================================
http://VegGuide.org               http://blog.urth.org
Your guide to all that's veg      House Absolute(ly Pointless)
============================================================*/



nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About