Do not copy __weakref__ from original _cls_dict (#410)

self._cls_dict["__weakref__"] holds a reference to self._cls, preventing
self._cls from being released after the new, slots-enabled class is
returned.

Fixes #407
3 files changed