J2 paper 0.2.1

Paul Moore pf_moore at yahoo.co.uk
Tue Aug 24 16:10:19 EDT 2004


"Robert Brewer" <fumanchu at amor.org> writes:

> The first draft of the J2 proposal is ready. You can read it here:
> http://www.aminus.org/rbre/python/pydec.html
>
> At this point, I am looking for comments regarding the proposal. Once I
> believe I have addressed a sufficient number of concerns, I will freeze
> the document and call for signatories, both for and against, then send
> it to Guido. Until that time, expect the draft to change multiple times
> each day (there's a meta tag with the version number if you care to
> check).

I have just read this - it's a very good document. I don't necessarily
agree with all of it, and I'm not sure I'm convinced by it, but it
makes a solid proposal to submit.

Some comments:

1. I differ on the "it doesn't matter what the keyword is" statement.
   On the contrary, my view could completely change depending on the
   keyword - I'd loathe "predef", whereas "using" is acceptable to me.
   Putting the proposal forward *without* an agreed keyword isn't
   (IMHO) fair to people who have this view.
2. I agree with the person who pointed out that the indentation makes
   the decorators merge visually with the function name. This is a
   definite point against the syntax, and should be at least noted in
   section "Arguments - I - 3 Additional benefits" paragraph 2. In
   fact, I could esily argue that it completely invalidates this
   point, swinging it in favour of @ syntax.

Also, I'd say that the proposal needs to be submitted with a full,
working patch. This isn't meant to be sour grapes, but I'd be
concerned if the proposal was submitted, Guido approved it, and then
it wasnt't possible to get a working version ready in time for the
next alpha. Regardless of any other consideration, I'm completely
against any delay of the 2.4 timescales for this.

>From a brief reading of the description attached to the current patch,
I have a couple of comments:

1. The patch doesn't (according to the comment) implement the
   __future__ import. This needs to be added before the proposal is
   submitted. And __future__ support for the interactive prompt may be
   needed as well - I'm not sure here, see PEP 236 for the detail.
2. Does the patch support decorating classes? The @ syntax *might* by
   now (in CVS), there was discussion of adding it but I'm not sure it
   went in. The patch should probably provide the same functionality
   as CVS @-syntax, rather than just 2.4a2.

Having said all this, I'd have to say that I'm still not sure I'm
swayed. I'm only ever going to be an occasional user of decorators, I
suspect, so I don't really care a *lot*, but I think I still prefer @
decorators.

Paul.
-- 
I don't know anything about music. In my line you don't have to. --
Elvis Presley



More information about the Python-list mailing list