How to return the object ("bpy.data.objects[...]") in python from Object in C

I’m using Cython to facilitate the creation of Blender extensions in python. But the answer can be given directly in C if you prefer.
I can reference the object C as follows:


...
def get_object(py_data_object):
    cdef Object *obedit = <Object *>PyC_RNA_AsPointer(<PyObject *>py_data_object, "Object")

But now how can I do in the other direction (from the Object C return the RNA)?