[Datetime-SIG] Calendar vs timespan calculations...

Guido van Rossum guido at python.org
Fri Jul 31 18:37:22 CEST 2015


[re-adding the list]

On Fri, Jul 31, 2015 at 6:21 PM, Łukasz Rekucki <lrekucki at gmail.com> wrote:

> On 31 July 2015 at 18:02, Guido van Rossum <guido at python.org> wrote:
> > On Fri, Jul 31, 2015 at 5:15 AM, Chris Barker <chris.barker at noaa.gov>
> wrote:
> >>
> >> On Thu, Jul 30, 2015 at 6:09 PM, Ethan Furman <ethan at stoneleaf.us>
> wrote:
> >>>
> >>> On 07/30/2015 06:04 PM, Tim Peters wrote:
> >>>
> >>>> I like Alexander's new tzstrict (subclass of tzinfo) idea best so far.
> >
> >
> > I like it too.
>
> What happens then when you substract a datetime with *strict* tzinfo
> and a *naive* one? Would A - B == - (B - A) still be true ?


That's for the authors of the new PEP to decide, really, but I think it
could be made to follow the strict rules in both cases, since clearly the
code isn't an old program requiring backward compatibility (how would such
a program end up with a strict tzinfo?).

-- 
--Guido van Rossum (python.org/~guido)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/datetime-sig/attachments/20150731/dce5925b/attachment.html>


More information about the Datetime-SIG mailing list