Skip to content

Commit

Permalink
fix: also capture templated decltype functions
Browse files Browse the repository at this point in the history
  • Loading branch information
alandtse committed Mar 21, 2023
1 parent cd97230 commit 591a5f4
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions vr_address_tools.py
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@
REL_ID: OFFSET_RELID_PATTERN,
REL_OFFSET: OFFSET_OFFSET_PATTERN,
}
FUNCTION_REGEX = r"(?:class (?P<class_decl>\w+)[&\w\s;:<>{=[\]*]*?)?(?P<return_type>[\w<>:*]+)\s+(?:\w+::)?(?P<func_name>[\w]+)\s*\((?P<args>[^)]*),?\s*\)[\w\s]*{(?:[\w\s=]*decltype\(&(?P<class>\w+)::(?P=func_name)+(?:<.*>)?\))?[&\w\s;:<>{=*]*REL(?:[\w:]*ID)\((?:(?P<id>\d*)|(?P<sseid>\d*),\s*(?P<aeid>\d*))\) };"
GENERIC_FOO_REGEX = r"(?P<return_type>[\w<>:*&]+)\s+(?:\w+::)?(?P<func_name>[\w]+)\s*\((?P<args>[^)]*)?\s*\)[\w\s]*{[&\w\s;:<>{=*/+-.]*_generic_foo<(?:(?P<id>\d*)),\s+(?P=return_type)(?:,\s*)?(?:(?P<class>\w+)\*)?.*>\(.*\);"
ARGS_REGEX = r"(?P<arg_pair>(?:const )?(?P<arg_type>[\w*&:_]+)\s+(?P<arg>[\w_]*)),?"
FUNCTION_REGEX_PARSE_DICT = {
Expand Down

0 comments on commit 591a5f4

Please sign in to comment.