On 05/21/2013 08:39 AM, Skip Montanaro wrote:
Don't confuse the use of "static" in Python with its use in C/C++.  From a post 
on StackOverflow:

    A staticmethod is a method that knows nothing about the class or instance 
it was called on. It just gets the
    arguments that were passed, no implicit first argument. It is basically 
useless in Python -- you can just use a
    module function instead of a staticmethod.

For there record, staticmethod is useful when you want to make it possible for 
subclasses to change behavior.

--
~Ethan~
--
http://mail.python.org/mailman/listinfo/python-list

Reply via email to