Martin Panter added the comment:

I think the proper way to suppress the link is :attr:`!__name__`.

However I am posting a patch which takes a different approach. I tweaked some 
of the entries under 
<https://docs.python.org/dev/library/stdtypes.html#special-attributes> that 
also apply to functions, etc. I invented the pseudo class name “definition” for 
this; better suggestions are welcome!

Then I converted the user-defined functions reference, as well as many other 
references, to :attr:`~definition.__name__` or similar, for these three 
attributes:

* definition.__name__
* definition.__qualname__
* object.__dict__

I also moved the index markup so that the index entries for the table of 
function attributes work.

----------
keywords: +patch
nosy: +vadmium
stage:  -> patch review
Added file: http://bugs.python.org/file39542/special-attr.patch

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

Reply via email to