Ram Rachum <cool...@cool-rr.com> added the comment:

So if int is officially a class, why not start doing :class:`int` instead of 
:func:`int`?

"they’re marked up as functions, so you should treat them as functions."

Here, I've treated staticmethod as a function:

    >>> assert isinstance(staticmethod, types.FunctionType)
    Traceback (most recent call last):
      File "<pyshell#1>", line 1, in <module>
        assert isinstance(staticmethod, types.FunctionType)
    AssertionError

I get an error.

So I understand that you are using Sphinx's :func: role in a liberal way; You 
consider it okay to use it to mark anything that is callable, regardless of 
whether it's a function or a class. Am I right?

This looks to me like an abuse of Sphinx notation. When I read documentation I 
don't want to be second-guessing the author's intentions. If someone writes 
:func:`whatever` I expect `whatever` to be a function and not a class.

Perhaps we need a :callable: role?

----------
status: closed -> open

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue10893>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to