Skip to content

Commit 6b820d9

Browse files
committed
Remove generator type check in raise_SIGINT_then_send_None
In the Cinder JIT we use a different type for generators, which breaks the test which uses this function. In general I believe the intent with generators is they have the right structure rather than type, so a failure to find the 'send()' method is arguably more correct if the wrong object is used.
1 parent f0d8583 commit 6b820d9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Modules/_testcapimodule.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1585,7 +1585,7 @@ raise_SIGINT_then_send_None(PyObject *self, PyObject *args)
15851585
{
15861586
PyGenObject *gen;
15871587

1588-
if (!PyArg_ParseTuple(args, "O!", &PyGen_Type, &gen))
1588+
if (!PyArg_ParseTuple(args, "O", &gen))
15891589
return NULL;
15901590

15911591
/* This is used in a test to check what happens if a signal arrives just

0 commit comments

Comments
 (0)