[Python-checkins] python/dist/src/Doc/lib libos.tex,1.99,1.100

loewis@users.sourceforge.net loewis@users.sourceforge.net
Wed, 16 Oct 2002 11:27:40 -0700


Update of /cvsroot/python/python/dist/src/Doc/lib
In directory usw-pr-cvs1:/tmp/cvs-serv7316/Doc/lib

Modified Files:
	libos.tex 
Log Message:
Add PyStructSequence_UnnamedField. Add stat_float_times.
Use integers in stat tuple, optionally floats in named fields.


Index: libos.tex
===================================================================
RCS file: /cvsroot/python/python/dist/src/Doc/lib/libos.tex,v
retrieving revision 1.99
retrieving revision 1.100
diff -C2 -d -r1.99 -r1.100
*** libos.tex	10 Oct 2002 18:24:52 -0000	1.99
--- libos.tex	16 Oct 2002 18:27:38 -0000	1.100
***************
*** 855,861 ****
  (time of most recent content modification or metadata change).
  
! \versionchanged [The time values are floats, measuring
!   seconds. Fractions of a second may be reported if the system
!   supports that]{2.3}
  
  On some Unix systems (such as Linux), the following attributes may
--- 855,862 ----
  (time of most recent content modification or metadata change).
  
! \versionchanged [If \function{stat_float_times} returns true, the time
! values are floats, measuring seconds. Fractions of a second may be
! reported if the system supports that. On Mac OS, the times are always
! floats. See \function{stat_float_times} for further discussion. ]{2.3}
  
  On some Unix systems (such as Linux), the following attributes may
***************
*** 898,901 ****
--- 899,928 ----
  \versionchanged
  [Added access to values as attributes of the returned object]{2.2}
+ \end{funcdesc}
+ 
+ \begin{funcdesc}{stat_float_times}{\optional{newvalue}}
+ Determine whether \class{stat_result} represents time stamps as float
+ objects.  If newval is True, future calls to stat() return floats, if
+ it is False, future calls return ints.  If newval is omitted, return
+ the current setting.
+ 
+ For compatibility with older Python versions, accessing
+ \class{stat_result} as a tuple always returns integers. For
+ compatibility with Python 2.2, accessing the time stamps by field name
+ also returns integers. Applications that want to determine the
+ fractions of a second in a time stamp can use this function to have
+ time stamps represented as floats. Whether they will actually observe
+ non-zero fractions depends on the system.
+ 
+ Future Python releases will change the default of this settings;
+ applications that cannot deal with floating point time stamps can then
+ use this function to turn the feature off.
+ 
+ It is recommended that this setting is only changed at program startup
+ time in the \var{__main__} module; libraries should never change this
+ setting. If an application uses a library that works incorrectly if
+ floating point time stamps are processed, this application should turn
+ the feature off until the library has been corrected.
+ 
  \end{funcdesc}