Fix bug #1598620: A ctypes structure cannot contain itself.

Backport from trunk.
3 files changed