[Matrix-SIG] An area where the C-API for NumPy 1.12 is not 100% compatible

David Ascher da@ski.org
Mon, 6 Sep 1999 15:28:34 -0700 (Pacific Daylight Time)


> [konrad]
> That should be a general problem with extension classes, and perhaps
> one should look for a general solution. Ideally, PyArg_ParseTuple()
> (or a similar function provided by the ExtensionClass module) would
> offer both direct type comparison and subclass checks. Then of course
> C modules would have to be adapted - but I'd prefer to impose this
> only once, when a definite solution is available.

I like that idea.  We could write a PyArg_ParseTupleExt (or some other
more useful name) which, if it finds an O= with a corresponding argument
which in an EC, does the class equality (not the type equality, btw, since
that is true for all EC's!), and e.g. when it sees a O<, does the
subclassing test as well.

I'll send a summary email to Guido and Jim Fulton, and pick their brains
on the topic.

--david