----- Original Message -----
From: "Dave Rolsky" <[EMAIL PROTECTED]>
To: "datetime" <datetime@perl.org>
Sent: Tuesday, September 06, 2005 4:39 PM
Subject: Re: DateTime.pm 0.30 coming up real soon now
On Tue, 6 Sep 2005, renard wrote:
The results should be obviously "correct" and not throw an unexpected
curve.
When I find the difference between 2 dates I expect to obtain the same
dates
when I add/subract the difference. If I don't then it raises a red flag
on the correctness of adding/
subtracting date duration...no matter what the documentation says.
I understand the difficulty when adding/subtracting months
July 4 - 1 month expect June 4
June 4 + 1 month expect July 4
July 31 - 1 month expect June 30
June 30 + 1 month expect July 30
However if I take the difference between 2 dates I definitely
expect to obtain the original end dates. I don't want to dig through the
documentation to find why it doesn't.
I'm not quite following this paragraph. In the second example (July ->
June -> July) are you saying those results are what you'd expect or not?
If they're not what you'd expect, what would you expect instead?
What I was trying to say that I can accept and understand July31 ->
June30 -> July30
when the duration is 1 month
However when the duration = dt2 - dt1 then I definetly expect
dt2 - duration = dt1
dt1 + duratiom = dt2
when I read that is not necessarily so and that I need to refer to
documentation
then for a newbie like me it becomes hard to swalow.
Perhaps a DateTime::SimpleDate would be what an occasional user like me
would need
The problem is (I think) that different people will have different
expectations of what's intuitive here, because if you think about it much
you realize that _almost nothing_ is intuitive when it comes to date(time)
math.
I know that more knowleadgeable and smarter people than I are working on
this module.
It was a plea to those people to remember the needs of datetime module.users
And yes that is as difficult to determine as to solve the datetime problems
-dave
/*===================================================
VegGuide.Org www.BookIRead.com
Your guide to all that's veg. My book blog
===================================================*/