Re: Decorator keyword options - brainstorming

Discussion in 'Python' started by David Vaughan, Aug 20, 2004.

  1. Paul McGuire wrote:
    > I'd say that something like "gerbil" should be right out!


    I don't know - it sounds fun. I vote:

    SpanishInquisition:
    staticmethod
    def foo():
    pass

    The guys at python-dev won't be expecting that one :)
    But seriously, there must be something literally pythonic we could
    propose.

    David Vaughan
     
    David Vaughan, Aug 20, 2004
    #1
    1. Advertising

  2. David Vaughan

    Peter Hansen Guest

    David Vaughan wrote:

    > The guys at python-dev won't be expecting that one :)
    > But seriously, there must be something literally pythonic we could
    > propose.


    I believe that would be any of the options involving a
    simple sequence of callables, which would be applied in order
    from start to finish (just as any Python programmer would
    expect). This was shot down for various reasons pretty early
    on, whether in the "list-after-def" form or the others.

    I think the "decorate:" option (with alternative keyword if
    there's a better) is the second most Pythonic shown to date...

    Most of the others are far too convoluted, or use such an
    uncommon (to Python) style of syntax, that the term "Pythonic"
    cannot yet be applied to them... but maybe after it's in the
    language the definition of the term will change. ;-)

    -Peter
     
    Peter Hansen, Aug 20, 2004
    #2
    1. Advertising

  3. David Vaughan wrote:
    > Paul McGuire wrote:
    >> I'd say that something like "gerbil" should be right out!

    >
    > I don't know - it sounds fun. I vote:
    >
    > SpanishInquisition:
    > staticmethod
    > def foo():
    > pass
    >
    > The guys at python-dev won't be expecting that one :)
    > But seriously, there must be something literally pythonic we could
    > propose.


    How about

    pythonic:
    staticmethod
    def foo():
    pass

    ?

    Reinhold

    --
    Wenn eine Linuxdistribution so wenig brauchbare Software wie Windows
    mitbrächte, wäre das bedauerlich. Was bei Windows der Umfang eines
    "kompletten Betriebssystems" ist, nennt man bei Linux eine Rescuedisk.
    -- David Kastrup in de.comp.os.unix.linux.misc
     
    Reinhold Birkenfeld, Aug 20, 2004
    #3
  4. Peter Hansen wrote:

    > I think the "decorate:" option (with alternative keyword if
    > there's a better) is the second most Pythonic shown to date...

    How about "def:" as the alternative keyword? Certaily this would
    stand out sufficiently.

    -Scott David Daniels
     
    Scott David Daniels, Aug 22, 2004
    #4
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Victor
    Replies:
    1
    Views:
    373
    Markus Wankus
    Jan 13, 2004
  2. Paul McGuire

    Decorator keyword options

    Paul McGuire, Aug 20, 2004, in forum: Python
    Replies:
    13
    Views:
    498
    =?iso-8859-1?Q?Fran=E7ois?= Pinard
    Aug 23, 2004
  3. glomde
    Replies:
    5
    Views:
    540
    glomde
    Mar 29, 2007
  4. Chariton Karamitas

    Two C++ snippets for brainstorming

    Chariton Karamitas, Dec 2, 2011, in forum: C++
    Replies:
    6
    Views:
    746
    John Tsiombikas
    Dec 10, 2011
  5. Wolfgang Nádasi-Donner
    Replies:
    8
    Views:
    173
    Wolfgang Nádasi-Donner
    Jul 31, 2005
Loading...

Share This Page