@@ -91,11 +91,11 @@ def extract_result_types(comment):
91
91
parsed.
92
92
"""
93
93
result_types = []
94
- m = re .search (r "Usable as: Any Matcher[\s\n]*$" , comment , re .S )
94
+ m = re .search ("Usable as: Any Matcher[\ \ s\n ]*$" , comment , re .S )
95
95
if m :
96
96
return ["*" ]
97
97
while True :
98
- m = re .match (r "^(.*)Matcher<([^>]+)>\s*,?[\s\n]*$" , comment , re .S )
98
+ m = re .match ("^(.*)Matcher<([^>]+)>\\ s*,?[\ \ s\n ]*$" , comment , re .S )
99
99
if not m :
100
100
if re .search (r"Usable as:\s*$" , comment ):
101
101
return result_types
@@ -106,9 +106,9 @@ def extract_result_types(comment):
106
106
107
107
108
108
def strip_doxygen (comment ):
109
- """Returns the given comment without \-escaped words."""
109
+ r """Returns the given comment without \-escaped words."""
110
110
# If there is only a doxygen keyword in the line, delete the whole line.
111
- comment = re .sub (r "^\\[^ \s]+\n" , r"" , comment , flags = re .M )
111
+ comment = re .sub ("^\\ \\ [^ \ \ s]+\n " , r"" , comment , flags = re .M )
112
112
113
113
# If there is a doxygen \see command, change the \see prefix into "See also:".
114
114
# FIXME: it would be better to turn this into a link to the target instead.
@@ -241,7 +241,7 @@ def act_on_decl(declaration, comment, allowed_types):
241
241
242
242
# Parse the various matcher definition macros.
243
243
m = re .match (
244
- """.*AST_TYPE(LOC)?_TRAVERSE_MATCHER(?:_DECL)?\(
244
+ r """.*AST_TYPE(LOC)?_TRAVERSE_MATCHER(?:_DECL)?\(
245
245
\s*([^\s,]+\s*),
246
246
\s*(?:[^\s,]+\s*),
247
247
\s*AST_POLYMORPHIC_SUPPORTED_TYPES\(([^)]*)\)
0 commit comments