Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion scripts/unity/func_name_list.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ def func_names_from_header(in_file, out_file):

with open(out_file, 'w') as f_out:
# Regex match all function names in the header file
x = re.findall(r"^\s*(?:\w+[*\s]+)+(\w+?)\s*\([^\\]*?\)\s*;",
x = re.findall(r"^\s*(?:\w+[*\s]+)+(\w+?)\s*\([\w\s,*\.\[\]]*?\)\s*;",
content, re.M | re.S)
for item in x:
f_out.write(item + "\n")
Expand Down
2 changes: 1 addition & 1 deletion scripts/unity/header_prepare.py
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ def header_prepare(in_file, out_file, out_wrap_file):
# Prepare file with functions prefixed with __wrap_ that will be used for
# mock generation.
func_pattern = re.compile(
r"^\s*((?:\w+[*\s]+)+)(\w+?\s*\([^\\{}#]*?\)\s*;)", re.M)
r"^\s*((?:\w+[*\s]+)+)(\w+?\s*\([\w\s,*\.\[\]]*?\)\s*;)", re.M)
content2 = func_pattern.sub(r"\n\1__wrap_\2", content)

with open(out_wrap_file, 'w') as f_wrap:
Expand Down