mirror of
https://github.com/python/cpython.git
synced 2025-10-06 23:21:06 +00:00
GH-91049: Introduce set vectorcall field API for PyFunctionObject (GH-92257)
Co-authored-by: Andrew Frost <adfrost@fb.com> Co-authored-by: Itamar Ostricher <itamarost@gmail.com>
This commit is contained in:
parent
e37ac5fbb6
commit
a41ed975e8
9 changed files with 115 additions and 3 deletions
|
@ -837,6 +837,11 @@ _Py_Specialize_LoadAttr(PyObject *owner, _Py_CODEUNIT *instr, PyObject *name)
|
|||
if (!function_check_args(descr, 2, LOAD_ATTR)) {
|
||||
goto fail;
|
||||
}
|
||||
uint32_t version = function_get_version(descr, LOAD_ATTR);
|
||||
if (version == 0) {
|
||||
goto fail;
|
||||
}
|
||||
write_u32(lm_cache->keys_version, version);
|
||||
/* borrowed */
|
||||
write_obj(lm_cache->descr, descr);
|
||||
write_u32(lm_cache->type_version, type->tp_version_tag);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue