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/2007-November/075080.html below:

[Python-Dev] Declaring setters with getters

[Python-Dev] Declaring setters with getters [Python-Dev] Declaring setters with gettersAahz aahz at pythoncraft.com
Thu Nov 1 02:51:47 CET 2007
On Thu, Nov 01, 2007, Greg Ewing wrote:
>
> But there's something that bothers me about the whole propery
> mechanism -- there's no straightforward way for a property accessor to
> call the inherited version from a base class.
>
> Wrapping property accessors up in decorators makes this worse. At
> least when the accessors are declared as separate functions you have
> a chance of grabbing an inherited one and calling it. But if they're
> buried inside property descriptors with no other reference to them,
> it's a lot harder to get hold of one.

That's why the property delegates to a normal method.

(Kudos to Martelli for the idea.)
-- 
Aahz (aahz at pythoncraft.com)           <*>         http://www.pythoncraft.com/

"Typing is cheap.  Thinking is expensive."  --Roy Smith
More information about the Python-Dev mailing list

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