| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
| |
Replace _PyInterpreterState_Get() function call with
_PyInterpreterState_GET_UNSAFE() macro which is more efficient but
don't check if tstate or interp is NULL.
_Py_GetConfigsAsDict() now uses _PyThreadState_GET().
|
|
|
|
|
|
|
|
|
| |
* sys.settrace(), sys.setprofile() and _lsprof.Profiler.enable() now
properly report PySys_Audit() error if "sys.setprofile" or
"sys.settrace" audit event is denied.
* Add _PyEval_SetProfile() and _PyEval_SetTrace() function: similar
to PyEval_SetProfile() and PyEval_SetTrace() but take a tstate
parameter and return -1 on error.
* Add _PyObject_FastCallTstate() function.
|
|
|
|
|
| |
Move get_recursion_depth() function from _testcapi to
_testinternalcapi to avoid accessing PyThreadState attributes
directly in _testcapi.
|
| |
|
| |
|
| |
|
|
|
|
|
| |
489) (GH-18608)
Co-authored-by: Victor Stinner <vstinner@python.org>
|
|
|
|
|
| |
489) (GH-18358)
Co-authored-by: Petr Viktorin <pviktori@redhat.com>
|
| |
|
|
|
|
|
|
| |
Fix the random.Random.seed() method when a bool is passed as the
seed.
PyObject_Vectorcall() was misused: use PyObject_CallOneArg() instead.
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add --with-platlibdir option to the configure script: name of the
platform-specific library directory, stored in the new sys.platlitdir
attribute. It is used to build the path of platform-specific dynamic
libraries and the path of the standard library.
It is equal to "lib" on most platforms. On Fedora and SuSE, it is
equal to "lib64" on 64-bit systems.
Co-Authored-By: Jan Matějek <jmatejek@suse.com>
Co-Authored-By: Matěj Cepl <mcepl@cepl.eu>
Co-Authored-By: Charalampos Stratakis <cstratak@redhat.com>
|
|
|
|
| |
Py_Initialize() calls PyEval_InitThreads() since Python 3.7. It's no
longer needed to call it explicitly.
|
|
|
|
|
| |
mode. (GH-16329)
Co-authored-by: Victor Stinner <vstinner@python.org>
|
|
|
|
| |
called with invalid base. (GH-18863)
|
| |
|
| |
|
|
|
| |
Co-authored-by: Victor Stinner <vstinner@python.org>
|
|
|
| |
For PEP 585 (this isn't in the PEP but is an obvious follow-up).
|
|
|
|
|
| |
set_herror builds a string by calling hstrerror but downcasts its return value to char *. It should be const char *.
Automerge-Triggered-By: @benjaminp
|
|
|
|
|
|
|
| |
(GH-16959)" (GH-18767)
This reverts commit e471e72977c83664f13d041c78549140c86c92de.
The mode will be removed from Python 3.10.
|
| |
|
| |
|
|
|
|
| |
are activated (GH-18705)
|
|
|
|
| |
exception raised. (GH-18656)
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
Modules/_testbuffer.c (GH-18637)
|
|
|
|
| |
Fix a regression where the C pickle module wouldn't allow unpickling from a
file-like object that doesn't expose a readinto() method.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
(GH-18604)
* bpo-39648: Expand math.gcd() and math.lcm() to handle multiple arguments.
* Simplify fast path.
* Difine lcm() without arguments returning 1.
* Apply suggestions from code review
Co-Authored-By: Mark Dickinson <dickinsm@gmail.com>
Co-authored-by: Mark Dickinson <dickinsm@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The truncate() method of io.BufferedReader() should raise
UnsupportedOperation when it is called on a read-only
io.BufferedReader() instance.
https://bugs.python.org/issue35950
Automerge-Triggered-By: @methane
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Update math.rst
* Update math.rst
* updated whats new
* Update test_math.py
* Update mathmodule.c
* Update mathmodule.c.h
* Update ACKS
* 📜🤖 Added by blurb_it.
* Update 3.9.rst
* Update 2020-02-18-12-37-16.bpo-39479.j3UcCq.rst
* Update math.rst
* Update 2020-02-18-12-37-16.bpo-39479.j3UcCq.rst
* Update test_math.py
* Update ACKS
* Update mathmodule.c.h
* Update mathmodule.c
* Update mathmodule.c.h
* Update mathmodule.c.h
Co-authored-by: blurb-it[bot] <43283697+blurb-it[bot]@users.noreply.github.com>
|
|
|
|
|
| |
489) (GH-18050)
https://bugs.python.org/issue1635741
|
|
|
|
| |
(GH-18030)
|
|
|
|
| |
(GH-18374)
|
| |
|
|
|
|
| |
489) (GH-18404)
|
| |
|
|
|
|
| |
`resource`, `shutil`, `signal`, `syslog` (GH-18407)
|
| |
|
|
|
|
|
|
|
| |
Move the dtoa.h header file to the internal C API as pycore_dtoa.h:
it only contains private functions (prefixed by "_Py").
The math and cmath modules must now be compiled with the
Py_BUILD_CORE macro defined.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
gcc -Wcast-qual turns up a number of instances of casting away constness of pointers. Some of these can be safely modified, by either:
Adding the const to the type cast, as in:
- return _PyUnicode_FromUCS1((unsigned char*)s, size);
+ return _PyUnicode_FromUCS1((const unsigned char*)s, size);
or, Removing the cast entirely, because it's not necessary (but probably was at one time), as in:
- PyDTrace_FUNCTION_ENTRY((char *)filename, (char *)funcname, lineno);
+ PyDTrace_FUNCTION_ENTRY(filename, funcname, lineno);
These changes will not change code, but they will make it much easier to check for errors in consts
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The bulk of this patch was generated automatically with:
for name in \
PyObject_Vectorcall \
Py_TPFLAGS_HAVE_VECTORCALL \
PyObject_VectorcallMethod \
PyVectorcall_Function \
PyObject_CallOneArg \
PyObject_CallMethodNoArgs \
PyObject_CallMethodOneArg \
;
do
echo $name
git grep -lwz _$name | xargs -0 sed -i "s/\b_$name\b/$name/g"
done
old=_PyObject_FastCallDict
new=PyObject_VectorcallDict
git grep -lwz $old | xargs -0 sed -i "s/\b$old\b/$new/g"
and then cleaned up:
- Revert changes to in docs & news
- Revert changes to backcompat defines in headers
- Nudge misaligned comments
|
|
|
|
|
| |
489) (GH-18065)
https://bugs.python.org/issue1635741
|