Put 'isExpandedMacro' info in the dump files
This commit is contained in:
parent
178568f41f
commit
f33a8a417f
|
@ -118,6 +118,7 @@ class Token:
|
||||||
isLogicalOp Is this token a logical operator: && ||
|
isLogicalOp Is this token a logical operator: && ||
|
||||||
isUnsigned Is this token a unsigned type
|
isUnsigned Is this token a unsigned type
|
||||||
isSigned Is this token a signed type
|
isSigned Is this token a signed type
|
||||||
|
isExpandedMacro Is this token a expanded macro token
|
||||||
varId varId for token, each variable has a unique non-zero id
|
varId varId for token, each variable has a unique non-zero id
|
||||||
variable Variable information for this token. See the Variable class.
|
variable Variable information for this token. See the Variable class.
|
||||||
function If this token points at a function call, this attribute has the Function
|
function If this token points at a function call, this attribute has the Function
|
||||||
|
@ -165,6 +166,7 @@ class Token:
|
||||||
isLogicalOp = False
|
isLogicalOp = False
|
||||||
isUnsigned = False
|
isUnsigned = False
|
||||||
isSigned = False
|
isSigned = False
|
||||||
|
isExpandedMacro = False
|
||||||
varId = None
|
varId = None
|
||||||
variableId = None
|
variableId = None
|
||||||
variable = None
|
variable = None
|
||||||
|
@ -223,6 +225,8 @@ class Token:
|
||||||
self.isComparisonOp = True
|
self.isComparisonOp = True
|
||||||
elif element.get('isLogicalOp'):
|
elif element.get('isLogicalOp'):
|
||||||
self.isLogicalOp = True
|
self.isLogicalOp = True
|
||||||
|
if element.get('isExpandedMacro'):
|
||||||
|
self.isExpandedMacro = True
|
||||||
self.linkId = element.get('link')
|
self.linkId = element.get('link')
|
||||||
self.link = None
|
self.link = None
|
||||||
if element.get('varId'):
|
if element.get('varId'):
|
||||||
|
|
|
@ -4860,6 +4860,8 @@ void Tokenizer::dump(std::ostream &out) const
|
||||||
else if (tok->tokType() == Token::eLogicalOp)
|
else if (tok->tokType() == Token::eLogicalOp)
|
||||||
out << " isLogicalOp=\"True\"";
|
out << " isLogicalOp=\"True\"";
|
||||||
}
|
}
|
||||||
|
if (tok->isExpandedMacro())
|
||||||
|
out << " isExpandedMacro=\"True\"";
|
||||||
if (tok->link())
|
if (tok->link())
|
||||||
out << " link=\"" << tok->link() << '\"';
|
out << " link=\"" << tok->link() << '\"';
|
||||||
if (tok->varId() > 0)
|
if (tok->varId() > 0)
|
||||||
|
|
Loading…
Reference in New Issue