MCPcopy Create free account
hub / github.com/MagicStack/asyncpg / PyDict_ContainsString

Function PyDict_ContainsString

asyncpg/protocol/record/pythoncapi_compat.h:886–895  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

884// gh-108323 added PyDict_ContainsString() to Python 3.13.0a1
885#if PY_VERSION_HEX < 0x030D00A1
886static inline int PyDict_ContainsString(PyObject *op, const char *key)
887{
888 PyObject *key_obj = PyUnicode_FromString(key);
889 if (key_obj == NULL) {
890 return -1;
891 }
892 int res = PyDict_Contains(op, key_obj);
893 Py_DECREF(key_obj);
894 return res;
895}
896#endif
897
898

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected