Merge branch 'diorcety-python_property'

* diorcety-python_property:
  Changes file entry for Python director property fix
  Python: Fix property access with director

Conflicts:
	CHANGES.current
This commit is contained in:
William S Fulton 2014-10-11 00:22:21 +01:00
commit 78b904764a
5 changed files with 181 additions and 3 deletions

View file

@ -871,16 +871,21 @@ public:
#else
tab4, "if (not static):\n",
#endif
tab4, tab4, "self.__dict__[name] = value\n",
tab4, tab4, "object.__setattr__(self, name, value)\n",
tab4, "else:\n",
tab4, tab4, "raise AttributeError(\"You cannot add attributes to %s\" % self)\n\n",
"\n", "def _swig_setattr(self, class_type, name, value):\n", tab4, "return _swig_setattr_nondynamic(self, class_type, name, value, 0)\n\n", NIL);
Printv(f_shadow,
"\n", "def _swig_getattr(self, class_type, name):\n",
"\n", "def _swig_getattr_nondynamic(self, class_type, name, static=1):\n",
tab4, "if (name == \"thisown\"):\n", tab8, "return self.this.own()\n",
tab4, "method = class_type.__swig_getmethods__.get(name, None)\n",
tab4, "if method:\n", tab8, "return method(self)\n", tab4, "raise AttributeError(name)\n\n", NIL);
tab4, "if method:\n", tab8, "return method(self)\n",
tab4, "if (not static):\n",
tab4, tab4, "return object.__getattr__(self, name)\n",
tab4, "else:\n",
tab4, tab4, "raise AttributeError(name)\n\n",
"def _swig_getattr(self, class_type, name):\n", tab4, "return _swig_getattr_nondynamic(self, class_type, name, 0)\n\n", NIL);
Printv(f_shadow,
"\n", "def _swig_repr(self):\n",