File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -7271,6 +7271,15 @@ get_const_us_per_minute(datetime_state *st) {
72717271 : PyLong_FromLong (60000000 );
72727272}
72737273
7274+ static inline PyObject *
7275+ get_const_sec_per_day (datetime_state * st ) {
7276+ return st && st -> seconds_per_day ? Py_NewRef (st -> seconds_per_day )
7277+ : PyLong_FromLong (24 * 3600 );
7278+ }
7279+
7280+ /* The rest are too big for 32-bit ints, but even
7281+ * us_per_week fits in 40 bits, so doubles should be exact.
7282+ */
72747283static inline PyObject *
72757284get_const_us_per_hour (datetime_state * st ) {
72767285 return st && st -> us_per_hour ? Py_NewRef (st -> us_per_hour )
@@ -7289,11 +7298,6 @@ get_const_us_per_week(datetime_state *st) {
72897298 : PyLong_FromDouble (604800000000.0 );
72907299}
72917300
7292- static inline PyObject *
7293- get_const_sec_per_day (datetime_state * st ) {
7294- return st && st -> seconds_per_day ? Py_NewRef (st -> seconds_per_day )
7295- : PyLong_FromLong (24 * 3600 );
7296- }
72977301
72987302static inline PyObject *
72997303get_const_epoch (datetime_state * st ) {
You can’t perform that action at this time.
0 commit comments