Skip to content

Commit 16b6605

Browse files
committed
fixed type hint parser
1 parent 0ffce28 commit 16b6605

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

parsers/parser.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -563,7 +563,7 @@ def parse_arguments(self, line):
563563
arguments = re.search(r'^\s*def \w*\((.*)\)', line)
564564

565565
# Parse type hints
566-
hints = dict(re.findall(r'(\w*)\s*:\s*(\w*\[[^:]*\]|\w*)\s*', arguments.group(1)))
566+
hints = dict(re.findall(r'(\w*)\s*:\s*(\w+\[[^:]*\]|\w+)\s*', arguments.group(1)))
567567

568568
# Remove type hints
569569
arguments = re.sub(r':\s*(\w*\[[^:]*\]|\w*)\s*', "", arguments.group(1))

0 commit comments

Comments
 (0)