mirror of https://github.com/mitsuhiko/flask.git
You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
17 lines
345 B
17 lines
345 B
13 years ago
|
import re
|
||
|
import inspect
|
||
|
|
||
|
|
||
|
_internal_mark_re = re.compile(r'^\s*:internal:\s*$(?m)')
|
||
|
|
||
|
|
||
|
def skip_member(app, what, name, obj, skip, options):
|
||
|
docstring = inspect.getdoc(obj)
|
||
|
if skip:
|
||
|
return True
|
||
|
return _internal_mark_re.search(docstring or '') is not None
|
||
|
|
||
|
|
||
|
def setup(app):
|
||
|
app.connect('autodoc-skip-member', skip_member)
|