https://bugs.kde.org/show_bug.cgi?id=400536

--- Comment #1 from Nicolás Alvarez <nicolas.alva...@gmail.com> ---
Turns out PEP 258 was rejected. However, PEP 257 (accepted) briefly mentions
this: "String literals occurring immediately after a simple assignment at the
top level of a module, class, or __init__ method are called 'attribute
docstrings'."

Sphinx also supports this syntax for attribute documentation, along with two
more:
http://www.sphinx-doc.org/en/master/usage/extensions/autodoc.html#directive-autoattribute

class Foo:
    """Docstring for class Foo."""

    #: Doc comment for class attribute Foo.bar.
    #: It can have multiple lines.
    bar = 1

    flox = 1.5   #: Doc comment for Foo.flox. One line only.

    baz = 2
    """Docstring for class attribute Foo.baz."""


Should we implement all three?

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to