@@ -72,29 +72,6 @@ _PySys_GetAttr(PyThreadState *tstate, PyObject *name)
7272 return value ;
7373}
7474
75- static PyObject *
76- sys_get_object_id (PyThreadState * tstate , _Py_Identifier * key )
77- {
78- PyObject * sd = tstate -> interp -> sysdict ;
79- if (sd == NULL ) {
80- return NULL ;
81- }
82- PyObject * exc_type , * exc_value , * exc_tb ;
83- _PyErr_Fetch (tstate , & exc_type , & exc_value , & exc_tb );
84- PyObject * value = _PyDict_GetItemIdWithError (sd , key );
85- /* XXX Suppress a new exception if it was raised and restore
86- * the old one. */
87- _PyErr_Restore (tstate , exc_type , exc_value , exc_tb );
88- return value ;
89- }
90-
91- PyObject *
92- _PySys_GetObjectId (_Py_Identifier * key )
93- {
94- PyThreadState * tstate = _PyThreadState_GET ();
95- return sys_get_object_id (tstate , key );
96- }
97-
9875static PyObject *
9976_PySys_GetObject (PyInterpreterState * interp , const char * name )
10077{
@@ -139,19 +116,6 @@ sys_set_object(PyInterpreterState *interp, PyObject *key, PyObject *v)
139116 }
140117}
141118
142- static int
143- sys_set_object_id (PyInterpreterState * interp , _Py_Identifier * key , PyObject * v )
144- {
145- return sys_set_object (interp , _PyUnicode_FromId (key ), v );
146- }
147-
148- int
149- _PySys_SetObjectId (_Py_Identifier * key , PyObject * v )
150- {
151- PyInterpreterState * interp = _PyInterpreterState_GET ();
152- return sys_set_object_id (interp , key , v );
153- }
154-
155119int
156120_PySys_SetAttr (PyObject * key , PyObject * v )
157121{
0 commit comments