diff -r eddacf81a237 -r 7f4cfe76b90c Utilities/ModuleParser.py --- a/Utilities/ModuleParser.py Sat Feb 23 19:11:05 2019 +0100 +++ b/Utilities/ModuleParser.py Sat Feb 23 22:03:27 2019 +0100 @@ -59,14 +59,18 @@ _py_getnext = re.compile( r""" - (?P<String> - \""" (?P<StringContents1> + (?P<Comment> + \#[^\n]*$ # Ignore triple quotes in comments + ) + +| (?P<String> + \""" (?P<StringContents1> [^"\\]* (?: (?: \\. | "(?!"") ) [^"\\]* )* ) - \""" + \""" | ''' (?P<StringContents2> [^'\\]* (?: @@ -813,6 +817,9 @@ conditionalsstack.append(thisindent) deltaindentcalculated = 0 + elif m.start("Comment") >= 0: + pass + else: assert 0, "regexp _getnext found something unexpected"