Skip to content

Commit e90156e

Browse files
committed
json: use PyAnyDict_Check()
1 parent 0acff5e commit e90156e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Modules/_json.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1597,7 +1597,7 @@ encoder_listencode_obj(PyEncoderObject *s, PyUnicodeWriter *writer,
15971597
_Py_LeaveRecursiveCall();
15981598
return rv;
15991599
}
1600-
else if (PyDict_Check(obj) || PyFrozenDict_Check(obj)) {
1600+
else if (PyAnyDict_Check(obj)) {
16011601
if (_Py_EnterRecursiveCall(" while encoding a JSON object"))
16021602
return -1;
16031603
rv = encoder_listencode_dict(s, writer, obj, indent_level, indent_cache);

0 commit comments

Comments
 (0)