Consider the following Python (runs in 2.x or 3.x):
class Outer(object): pass class Inner(object): def __init__(self): print(\"Inner.self\", s
Can't be done. But with a bit of redesign:
class Outer(object): pass class _Inner(object): def __init__(self, outobj): self.outobj = outobj def Inner(self): return self._Inner(self) o = Outer() i = o.Inner() print o, i.outobj