In my current
Proof of concept, I use PyObject* typing=PyImport_ImportModule("typing");
and it's enough.
At time, I am not an expert of all the source code.
From my understanding, the buildin type must be enough to use Python, without other modules.
It is just a pure CPU code. If I'm right, to add the operator __or__() and to update the isinstance() and issubclass(), I must have the _GenericAlias accessible without other modules.
I can not import the module typing in isinstance() otherwise an infinite recursion arrives. I use a "bad trick" to resolve this problem.
The code must be better if I can have direct access to _GenericAlias type.
So, I imagine this class must be in buildin, or indirectly accessible by buildin methods and functions, without the import of typing.
What do you think?