Skip to content

Commit 41f6fa6

Browse files
fix news and formatting
1 parent 08ef4d8 commit 41f6fa6

File tree

3 files changed

+6
-3
lines changed

3 files changed

+6
-3
lines changed

Include/internal/pycore_code.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -309,7 +309,7 @@ int _Py_Specialize_LoadMethod(PyObject *owner, _Py_CODEUNIT *instr, PyObject *na
309309
int _Py_Specialize_BinarySubscr(PyObject *sub, PyObject *container, _Py_CODEUNIT *instr);
310310
int _Py_Specialize_BinaryAdd(PyObject *left, PyObject *right, _Py_CODEUNIT *instr);
311311
int _Py_Specialize_BinaryMultiply(PyObject *left, PyObject *right, _Py_CODEUNIT *instr);
312-
_Py_Specialize_CallFunction(PyObject *callable, _Py_CODEUNIT *instr, int nargs, SpecializedCacheEntry *cache, PyObject *builtins);
312+
int _Py_Specialize_CallFunction(PyObject *callable, _Py_CODEUNIT *instr, int nargs, SpecializedCacheEntry *cache, PyObject *builtins);
313313

314314
#define PRINT_SPECIALIZATION_STATS 0
315315
#define PRINT_SPECIALIZATION_STATS_DETAILED 9
Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
Setup initial specialization infrastructure for the ``CALL_FUNCTION`` opcode.
2-
Implemented two initial specializations for ``PyCFunctionObject``:
2+
Implemented initial specializations for C function calls:
33

44
* ``CALL_FUNCTION_BUILTIN_O`` for ``METH_O`` flag.
55

66
* ``CALL_FUNCTION_BUILTIN_FAST`` for ``METH_FASTCALL`` flag without keywords.
7+
8+
* ``CALL_FUNCTION_LEN`` for ``len(o)``.
9+
10+
* ``CALL_FUNCTION_ISINSTANCE`` for ``isinstance(o, t)``.

Python/specialize.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1241,7 +1241,6 @@ static int
12411241
specialize_c_call(PyObject *callable, _Py_CODEUNIT *instr, int nargs,
12421242
SpecializedCacheEntry *cache, PyObject *builtins)
12431243
{
1244-
_PyAdaptiveEntry *cache0 = &cache->adaptive;
12451244
_PyObjectCache *cache1 = &cache[-1].obj;
12461245
if (PyCFunction_GET_FUNCTION(callable) == NULL) {
12471246
return 1;

0 commit comments

Comments
 (0)