public static IntPtr tp_descr_get(IntPtr op, IntPtr instance, IntPtr owner)
{
ConstructorBinding self = (ConstructorBinding)GetManagedObject(op);
if (self == null)
{
return IntPtr.Zero;
}
// It doesn't seem to matter if it's accessed through an instance (rather than via the type).
/*if (instance != IntPtr.Zero) {
// This is ugly! PyObject_IsInstance() returns 1 for true, 0 for false, -1 for error...
if (Runtime.PyObject_IsInstance(instance, owner) < 1) {
return Exceptions.RaiseTypeError("How in the world could that happen!");
}
}*/
Runtime.XIncref(self.pyHandle); // Decref'd by the interpreter.
return self.pyHandle;
}