8000 gh-117398: Isolate _datetime (3.13.0a6 PoC) with AC by neonene · Pull Request #118337 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

gh-117398: Isolate _datetime (3.13.0a6 PoC) with AC #118337

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 53 commits into from
Closed
Changes from 1 commit
Commits
Show all changes
53 commits
Select commit Hold shift + click to select a range
4a418cb
import poc313a5 diff
neonene Apr 26, 2024
80084da
import poc313a5 diff
neonene Apr 26, 2024
23bf9b4
module, classes
neonene Apr 26, 2024
286a284
timedelta_total_seconds()
neonene Apr 26, 2024
8ba2af7
date.fromtimestamp() update
neonene Apr 26, 2024
b21bded
date.fromordinal()
neonene Apr 26, 2024
c1f6a75
date.fromisocalendar() with converter
neonene Apr 26, 2024
bd99b42
date.strftime()
neonene Apr 26, 2024
126b652
date.isocalendar()
neonene Apr 26, 2024
8e31f9d
date.replace() update
neonene Apr 26, 2024
109bea7
date.__replace__()
neonene Apr 26, 2024
25bf57b
tzinfo.fromutc()
neonene Apr 26, 2024
82c65ce
timezone.tzname()
neonene Apr 26, 2024
25dbfe9
timezone.utcoffset()
neonene Apr 26, 2024
af1eaf5
timezone.dst()
neonene Apr 26, 2024
0b5c97c
timezone.fromutc()
neonene Apr 26, 2024
903d26f
time.utcoffset()
neonene Apr 26, 2024
e4f6b7c
time.dst()
neonene Apr 26, 2024
569bc03
time.tzname()
neonene Apr 26, 2024
d0556d0
time.isoformat()
neonene Apr 26, 2024
8000 faf3772
time.strftime()
neonene Apr 26, 2024
489f173
time.replace() update
neonene Apr 26, 2024
fcf8c32
time.__replace__()
neonene Apr 26, 2024
af9c28e
time.fromisoformat()
neonene Apr 26, 2024
0138f9b
datetime.now() update
neonene Apr 26, 2024
991b858
datetime.fromtimestamp()
neonene Apr 26, 2024
a2cff70
datetime_fromtimestamp_capi()
neonene Apr 26, 2024
3811a3f
datetime.strptime()
neonene Apr 26, 2024
a48202b
datetime.combine()
neonene Apr 26, 2024
492fe6f
datetime.fromisoformat()
neonene Apr 26, 2024
92e6ed2
datetime.tzname()
neonene Apr 26, 2024
5c89a91
datetime.utcoffset()
neonene Apr 26, 2024
de23ca5
datetime.dst()
neonene Apr 26, 2024
c2b315e
datetime.isoformat()
neonene Apr 26, 2024
2c23667
datetime.replace() upadte
neonene Apr 26, 2024
e5b1db0
datetime.__replace__()
neonene Apr 26, 2024
0c237bc
datetime.astimezone()
neonene Apr 26, 2024
e210cc8
datetime.timetuple()
neonene Apr 26, 2024
86bbbab
datetime.timestamp()
neonene Apr 26, 2024
610b30b
datetime.date()
neonene Apr 26, 2024
a3b75f9
datetime.time()
neonene Apr 26, 2024
a9f821d
datetime.timetz()
neonene Apr 26, 2024
5188e7b
datetime.utctimetuple()
neonene Apr 26, 2024
7823d6b
update _datetimemodule.c.h
neonene Apr 26, 2024
0720cf9
regen
neonene Apr 26, 2024
f474feb
Update ignored.tsv
neonene Apr 26, 2024
1ed62de
fix gil-disabled test
neonene Apr 28, 2024
ccb230f
Merge branch 'main' into poc313clinic
neonene Apr 28, 2024
cc0c974
add missing docstr for *.__replace__()
neonene Apr 28, 2024
49b16c0
apply PR: Access C-API via PyInterpreterState
neonene May 1, 2024
163b209
Merge branch 'main' into poc313clinic
neonene May 1, 2024
2637e04
edit fix
neonene May 1, 2024
54ea8a6
Merge branch 'main' into poc313clinic
neonene May 4, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
datetime.timetz()
  • Loading branch information
neonene committed Apr 26, 2024
commit a9f821d3aebc95d472c42b8e4ee48d45c5b8f401
19 changes: 14 additions & 5 deletions Modules/_datetimemodule.c
Original file line number Diff line number Diff line change
Expand Up @@ -7007,10 +7007,21 @@ datetime_datetime_gettime_impl(PyDateTime_DateTime *self,
DATE_GET_FOLD(self));
}

/*[clinic input]
datetime.datetime.timetz as datetime_datetime_gettimetz

defcls: defining_class
/

Return time object with same time and tzinfo.
[clinic start generated code]*/

static PyObject *
datetime_gettimetz(PyDateTime_DateTime *self, PyObject *Py_UNUSED(ignored))
datetime_datetime_gettimetz_impl(PyDateTime_DateTime *self,
PyTypeObject *defcls)
/*[clinic end generated code: output=5dd413b4496a15d7 input=5e303916b45c585f]*/
{
datetime_state *st = find_module_state_by_def(Py_TYPE(self));
datetime_state *st = get_module_state_by_cls(defcls);
return new_time(st,
DATE_GET_HOUR(self),
DATE_GET_MINUTE(self),
Expand Down Expand Up @@ -7128,9 +7139,7 @@ static PyMethodDef datetime_methods[] = {

DATETIME_DATETIME_GETDATE_METHODDEF
DATETIME_DATETIME_GETTIME_METHODDEF

{"timetz", (PyCFunction)datetime_gettimetz, METH_NOARGS,
PyDoc_STR("Return time object with same time and tzinfo.")},
DATETIME_DATETIME_GETTIMETZ_METHODDEF

{"ctime", (PyCFunction)datetime_ctime, METH_NOARGS,
PyDoc_STR("Return ctime() style string.")},
Expand Down
0