[Python-Dev] Re: Static method and class method comments

Skip Montanaro skip at pobox.com
Wed Jul 25 19:54:05 EDT 2001


    Paul> Agree strongly. This will also be a problem for documentation
    Paul> generation tools, type extraction tools and class browsers. I
    Paul> believe it would be easy to add a contextual keyword

    >> class C:
    >>     def static foo(x, y):
    >>         print "classmethod", x, y

Even better yet, why not simply reuse the class keyword in this context:

    class C:
        def class foo(x, y):
            print "classmethod", x, y

-- 
Skip Montanaro (skip at pobox.com)
http://www.mojam.com/
http://www.musi-cal.com/




More information about the Python-list mailing list