A RetroSearch Logo

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

Search Query:

Showing content from http://mail.python.org/pipermail/python-dev/2004-April/043968.html below:

[Python-Dev] Re: PEP 318: Decorators last before colon

[Python-Dev] Re: PEP 318: Decorators last before colonRussell E. Owen rowen at cesmail.net
Fri Apr 2 16:01:03 EST 2004
In article <20040402105535.0526c27d.casey at zope.com>,
 Casey Duncan <casey at zope.com> wrote:

> Or how about as?
> 
>   as classmethod:
> 
>      def jinkies(cls):
>          pass
> 
> Which seems nice in the face of other declarations:
> 
>   as protected(some_permission):
> 
>      def zoinks(self, scooby, snack):
>          pass
> 
>      def jinkies(self):
>          pass
> 
> or
> 
>   [protected_by(some_permission)]:
> 
>       def dangerous(self, risk):
>           pass

I like this a lot. The effort to avoid new keywords, though laudable in 
many ways, comes at the cost of increased use of punctuation.

I generally find punctuation harder to read than keywords. Also, it is 
usually incomprehensible to someone unfamiliar with the language. The 
relative lack of punctuation in python as compared, say, to C is one if 
its great strengths, to my mind. It is one reason Python reads so much 
like pseudocode (or did before some of the recent changes such as list 
comprehensions -- very useful but a classic example of the problem of 
overloading punctuation).

I'd be very sad to see [] used for yet some other purpose.

-- Russell


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