Skip to content

Commit 7f29c80

Browse files
authored
fix autolink error that occurs when "See Also" line is succeeded by "--------" (#197)
* mat_types.py: fix bug when parsing mlapp files that have no description * fix autolink error that occurs when "See Also" line is succeeded by "--------" This usually happens when using numpy syntax docstrings.
1 parent 30b7c3d commit 7f29c80

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

sphinxcontrib/mat_documenters.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -203,7 +203,8 @@ def auto_link_see_also(self, docstrings):
203203
if is_see_also_line:
204204
# find name
205205
match = see_also_cond_re.search(line)
206-
entries_str = match.group(2) # the entries
206+
if match is not None:
207+
entries_str = match.group(2) # the entries
207208
elif match := see_also_re.search(line):
208209
is_see_also_line = True # line begins with "See also"
209210
entries_str = match.group(2) # the entries

0 commit comments

Comments
 (0)