diff options
Diffstat (limited to 'pylint/extensions/_check_docs_utils.py')
-rw-r--r-- | pylint/extensions/_check_docs_utils.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/pylint/extensions/_check_docs_utils.py b/pylint/extensions/_check_docs_utils.py index a995e15e2..594bd860e 100644 --- a/pylint/extensions/_check_docs_utils.py +++ b/pylint/extensions/_check_docs_utils.py @@ -694,8 +694,9 @@ class NumpyDocstring(GoogleDocstring): ) re_returns_line = re.compile(r""" - \s* ({type})$ # type declaration - \s* (.*) # optional description + \s* (?:\w+\s+:\s+)? # optional name + ({type})$ # type declaration + \s* (.*) # optional description """.format( type=GoogleDocstring.re_multiple_type, ), re.X | re.S | re.M) |