#!/usr/local/bin/python2 class C(object): __slots__ = ('_a') def __init__(self): self._a = 0 class C2(C): pass c = C2() c.a = 1