Skip to content

Commit 73ee354

Browse files
themarpehenryiii
authored andcommitted
Added capability to parse @returns and fixed @authors and @throws
1 parent e813412 commit 73ee354

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

pybind11_mkdoc/mkdoc_lib.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -124,17 +124,18 @@ def process_comment(comment):
124124
r'\n\n$Template parameter ``\2``:\n\n', s)
125125

126126
for in_, out_ in {
127+
'returns': 'Returns',
127128
'return': 'Returns',
128-
'author': 'Author',
129129
'authors': 'Authors',
130+
'author': 'Author',
130131
'copyright': 'Copyright',
131132
'date': 'Date',
132133
'remark': 'Remark',
133134
'sa': 'See also',
134135
'see': 'See also',
135136
'extends': 'Extends',
136-
'throw': 'Throws',
137-
'throws': 'Throws'
137+
'throws': 'Throws',
138+
'throw': 'Throws'
138139
}.items():
139140
s = re.sub(r'[\\@]%s\s*' % in_, r'\n\n$%s:\n\n' % out_, s)
140141

0 commit comments

Comments
 (0)