I like it. It's obvious from the field name what problem it solves, and which value of the flag corresponds to which instant in time.
________________________________________ From: Datetime-SIG <[email protected]> on behalf of Carl Meyer <[email protected]> Sent: Tuesday, August 25, 2015 14:48 To: Alexander Belopolsky Cc: datetime-sig Subject: Re: [Datetime-SIG] PEP 495 Q & A On 08/25/2015 01:46 PM, Alexander Belopolsky wrote: > > On Tue, Aug 25, 2015 at 3:39 PM, Carl Meyer <[email protected] > <mailto:[email protected]>> wrote: >> >> Another possible name for the flag/index just occurred to me: what about >> `which`? > > That was in my very first proposal: > > """ > In other words, instead of localtime(dt, isdst=-1), we may want > localtime(dt, which=0) where "which" is used to resolve the ambiguity: > "which=0" means return the first (in UTC order) of the two times and > "which=1" means return the second. (In the non-ambiguous cases "which" is > ignored.) > """ -- https://mail.python.org/pipermail/python-dev/2015-April/139099.html > > The name did not catch up. Ha! Well in that case, consider this a vote of confidence in your intuition -- I think it's the best of the options that have been discussed. Carl _______________________________________________ Datetime-SIG mailing list [email protected] https://mail.python.org/mailman/listinfo/datetime-sig The PSF Code of Conduct applies to this mailing list: https://www.python.org/psf/codeofconduct/
