[Python-Dev] Decorators: vertical bar syntax (original) (raw)
Mark 'Kamikaze' Hughes kamikaze at kuoi.asui.uidaho.edu
Mon Aug 9 02:25:56 CEST 2004
- Previous message: [Python-Dev] Decorators: vertical bar syntax
- Next message: [Python-Dev] Decorators: vertical bar syntax
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Sat, Aug 07, 2004 at 12:35:17AM -0400 in <41145C05.1020501 at gradient.cis.upenn.edu>, Edward Loper <edloper at gradient.cis.upenn.edu> spake:
The new "vertical bar" syntax was proposed recently, and has gotten almost unanimously positive feedback. In particular, of 17 responses to the syntax, only one has been negative (see table, below). I'm including both of the following variants: |classmethod |accepts(int, int) |returns(float) def foo(arg1, arg2): ... def foo(arg1, arg2): |classmethod |accepts(int, int) |returns(float) ... (I prefer the second, but would be happy with either.) The one negative comment was that "|" can look similar to "I" or "l", depending on the font; but it's only an issue for some fonts, and it should be largely mitigated by syntax-highlighting. So I wanted to see if anyone has anything negative to say about this syntax (or one of its variants). If possible, please respond by updating the wiki, rather than by email. This syntax is listed under H (pre-def) and E2 (post-def). You will need to sign in before you can edit the wiki. Wiki: <http://www.python.org/cgi-bin/moinmoin/PythonDecorators>
-1. I think vbar-before is an extremely hard syntax to read, and vbar-after is extremely misleading (but I don't like where docstrings are, either). Wiki updated.
-- <a href="http://kuoi.asui.uidaho.edu/~kamikaze/"> Mark Hughes "Doing the impossible makes us mighty." -Captain Malcolm Reynolds, Firefly
- Previous message: [Python-Dev] Decorators: vertical bar syntax
- Next message: [Python-Dev] Decorators: vertical bar syntax
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]