summaryrefslogtreecommitdiffstats
path: root/Doc/whatsnew/whatsnew23.tex
diff options
context:
space:
mode:
authorMartin v. Löwis <martin@v.loewis.de>2002-10-16 18:27:39 (GMT)
committerMartin v. Löwis <martin@v.loewis.de>2002-10-16 18:27:39 (GMT)
commitf607bdaa77475ec8c94614414dc2cecf8fd1ca0a (patch)
tree16aa4184fa6266a4927896483282899efcbcced8 /Doc/whatsnew/whatsnew23.tex
parent5b1614d568b94d32493249427ba86b4f272ae4e0 (diff)
downloadcpython-f607bdaa77475ec8c94614414dc2cecf8fd1ca0a.zip
cpython-f607bdaa77475ec8c94614414dc2cecf8fd1ca0a.tar.gz
cpython-f607bdaa77475ec8c94614414dc2cecf8fd1ca0a.tar.bz2
Add PyStructSequence_UnnamedField. Add stat_float_times.
Use integers in stat tuple, optionally floats in named fields.
Diffstat (limited to 'Doc/whatsnew/whatsnew23.tex')
-rw-r--r--Doc/whatsnew/whatsnew23.tex25
1 files changed, 25 insertions, 0 deletions
diff --git a/Doc/whatsnew/whatsnew23.tex b/Doc/whatsnew/whatsnew23.tex
index 85f6643..2b14698 100644
--- a/Doc/whatsnew/whatsnew23.tex
+++ b/Doc/whatsnew/whatsnew23.tex
@@ -1067,6 +1067,31 @@ in \module{xml.dom.minidom} can now generate XML output in a
particular encoding, by specifying an optional encoding argument to
the \method{toxml()} and \method{toprettyxml()} methods of DOM nodes.
+\item The \function{stat} family of functions can now report fractions
+of a second in a time stamp. Similar to \function{time.time}, such
+time stamps are represented as floats.
+
+During testing, it was found that some applications break if time
+stamps are floats. For compatibility, when using the tuple interface
+of the \class{stat_result}, time stamps are represented as integers.
+When using named fields (first introduced in Python 2.2), time stamps
+are still represented as ints, unless \function{os.stat_float_times}
+is invoked:
+
+\begin{verbatim}
+>>> os.stat_float_times(True)
+>>> os.stat("/tmp").st_mtime
+1034791200.6335014
+\end{verbatim}
+
+In Python 2.4, the default will change to return floats.
+
+Application developers should use this feature only if all their
+libraries work properly when confronted with floating point time
+stamps (or use the tuple API). If used, the feature should be
+activated on application level, instead of trying to activate it on a
+per-use basis.
+
\end{itemize}