Open
Description
@malemburg pointed that the documentation of SystemError
only refers to CPython internal errors as the source.
https://docs.python.org/3/library/exceptions.html#SystemError
On practice, SystemError is also raised on improper use of the C API (like NULL pointer, or negative size, or wrong type in the concrete API) if it is possible to detect such error and it is not too costly (macros usually lack any argument checks). An alternative to SystemError is a crash or memory corruption. Currently the main source of SystemError is errors in third-party extensions, not in the Python core or standard extensions.
The documentation looks outdated, perhaps it predates the public C API.