sphinx/tests/roots/test-ext-autodoc/target/slots.py
2025-01-03 01:33:14 +00:00

25 lines
410 B
Python

class Foo:
"""docstring"""
__slots__ = ['attr']
class Bar:
"""docstring"""
__slots__ = {
'attr1': 'docstring of attr1',
'attr2': 'docstring of attr2',
'attr3': None,
}
__annotations__ = {'attr1': int}
def __init__(self):
self.attr2 = None #: docstring of instance attr2
class Baz:
"""docstring"""
__slots__ = 'attr' # NoQA: PLC0205