A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2003-March/034198.html below:

[Python-Dev] How to suppress instance __dict__?

[Python-Dev] How to suppress instance __dict__? [Python-Dev] How to suppress instance __dict__?Martin v. Löwis martin@v.loewis.de
23 Mar 2003 09:24:51 +0100
David Abrahams <dave@boost-consulting.com> writes:

> Yes, I can define __getstate__, __setstate__, and __getinitargs__ (the
> only one that can actually do any work, since ints are immutable),
> but I was wondering if there's a more straightforward way to suppress
> the instance __dict__ in the derived classes.

Setting tp_dictoffset to 0 might help. However, I'm unsure what
consequences this has; read the source.

Regards,
Martin




RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4