Staging
v0.5.1
https://github.com/python/cpython
Revision 63376228a3f2d3ac4a21a10c0653c3b984c2d686 authored by Eric Smith on 05 May 2009, 14:04:18 UTC, committed by Eric Smith on 05 May 2009, 14:04:18 UTC
1 parent 86a05ec
Raw File
Tip revision: 63376228a3f2d3ac4a21a10c0653c3b984c2d686 authored by Eric Smith on 05 May 2009, 14:04:18 UTC
Issue #5920: Changed format.__float__ and complex.__float__ to use a precision of 12 when using the empty presentation type. This more closely matches str()'s behavior and reduces surprises when adding alignment flags to an empty format string. Patch by Mark Dickinson.
Tip revision: 6337622
timefuncs.h
/*  timefuncs.h
 */

/* Utility function related to timemodule.c. */

#ifndef TIMEFUNCS_H
#define TIMEFUNCS_H
#ifdef __cplusplus
extern "C" {
#endif


/* Cast double x to time_t, but raise ValueError if x is too large
 * to fit in a time_t.  ValueError is set on return iff the return
 * value is (time_t)-1 and PyErr_Occurred().
 */
PyAPI_FUNC(time_t) _PyTime_DoubleToTimet(double x);


#ifdef __cplusplus
}
#endif
#endif  /* TIMEFUNCS_H */
back to top