ISA parser: Match /* */ and // style comments.
Comments should not be scanned for operands, and we should look for both /* */ style and // style.
This commit is contained in:
parent
87d687e242
commit
f4dc64655f
|
@ -856,7 +856,8 @@ class SubOperandList(OperandList):
|
|||
|
||||
# Regular expression object to match C++ comments
|
||||
# (used in findOperands())
|
||||
commentRE = re.compile(r'//.*\n')
|
||||
commentRE = re.compile(r'(^)?[^\S\n]*/(?:\*(.*?)\*/[^\S\n]*|/[^\n]*)($)?',
|
||||
re.DOTALL | re.MULTILINE)
|
||||
|
||||
# Regular expression object to match assignment statements
|
||||
# (used in findOperands())
|
||||
|
|
Loading…
Reference in a new issue