From: Alexander Belopolsky Date: Thu, 20 Jan 2011 19:51:31 +0000 (+0000) Subject: Corrected the entry about new year range in the time module. X-Git-Tag: v3.2rc2~93 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=9ee94dec184631e16bcf50e4bfdd7e26e8e9ace0;p=python Corrected the entry about new year range in the time module. --- diff --git a/Doc/whatsnew/3.2.rst b/Doc/whatsnew/3.2.rst index eebee5034e..f983af694a 100644 --- a/Doc/whatsnew/3.2.rst +++ b/Doc/whatsnew/3.2.rst @@ -935,11 +935,19 @@ datetime and time after 1900. The new supported year range is from 1000 to 9999 inclusive. * The rules for two-digit years in time tuples have changed. Now, the - :func:`time.asctime` and :func:`time.strftime` functions will format any year - when :attr:`time.accept2dyear` is false and will accept four-digit years - otherwise. The :func:`time.mktime` and :func:`time.strftime` functions now - accept full range supported by the operating system. Conversion of two-digit - years to four-digit is deprecated. + :func:`time.asctime`, :func:`time.strftime` and :func:`time.mktime` + functions will accept any two- or four-digit year when + :attr:`time.accept2dyear` is true. Two-digit years are converted to + four-digits using the same heuristics as before, but a deprecation + warning will be issued whenever such conversion occurs. + +* The :func:`time.asctime`, :func:`time.mktime`, and + :func:`time.strftime` functions are no longer restricted to years + after 1900. Now, when :attr:`time.accept2dyear` is false, the + :func:`time.asctime` function will accept any year that fits in + a C int, while :func:`time.mktime` and :func:`time.strftime` + functions will accept full range supported by the corresponding + operating system functions. (Contributed by Alexander Belopolsky and Victor Stinner.)