[Python-Dev] query: docstring formatting in python distutils code

Georg Brandl g.brandl at gmx.net
Fri Jul 9 08:51:30 CEST 2010


Am 09.07.2010 00:01, schrieb Fred Drake:
> On Thu, Jul 8, 2010 at 5:42 PM, Alexander Belopolsky
> <alexander.belopolsky at gmail.com> wrote:
>> I am against mark-up in doc-strings, but this problem can be easily
>> solved by placing a magic character at __doc__[0] to indicate that the
>> rest is  (mini)reST.

Ugh. :)

> Or __docformat__ can be set appropriately.  See:
> 
>     http://www.python.org/dev/peps/pep-0258/#id42

Yes, but[tm] it is not always easy to find the correct module to look for
__docformat__ when given an object.

Georg

-- 
Thus spake the Lord: Thou shalt indent with four spaces. No more, no less.
Four shall be the number of spaces thou shalt indent, and the number of thy
indenting shall be four. Eight shalt thou not indent, nor either indent thou
two, excepting that thou then proceed to four. Tabs are right out.



More information about the Python-Dev mailing list