improve pointer level calc for []
This commit is contained in:
parent
9e7d82fc52
commit
3cc00eaf8f
|
@ -5199,13 +5199,13 @@ PEvalStatement CppParser::doCreateEvalVariable(
|
||||||
pointerLevel,
|
pointerLevel,
|
||||||
templateParams);
|
templateParams);
|
||||||
}
|
}
|
||||||
if (!varStatement->args.isEmpty()) {
|
// if (!varStatement->args.isEmpty()) {
|
||||||
int j = 0;
|
// int j = 0;
|
||||||
while ((j = varStatement->args.indexOf("[", j)) != -1) {
|
// while ((j = varStatement->args.indexOf("[", j)) != -1) {
|
||||||
++j;
|
// ++j;
|
||||||
pointerLevel++;
|
// pointerLevel++;
|
||||||
}
|
// }
|
||||||
}
|
// }
|
||||||
// qDebug()<<"parse ..."<<baseType<<pointerLevel;
|
// qDebug()<<"parse ..."<<baseType<<pointerLevel;
|
||||||
return std::make_shared<EvalStatement>(
|
return std::make_shared<EvalStatement>(
|
||||||
baseType,
|
baseType,
|
||||||
|
@ -5359,7 +5359,7 @@ PStatement CppParser::doParseEvalTypeInfo(
|
||||||
level++;
|
level++;
|
||||||
baseType="";
|
baseType="";
|
||||||
syntaxer.resetState();
|
syntaxer.resetState();
|
||||||
syntaxer.setLine(effectiveTypeStatement->type,0);
|
syntaxer.setLine(effectiveTypeStatement->type+effectiveTypeStatement->args,0);
|
||||||
int bracketLevel = 0;
|
int bracketLevel = 0;
|
||||||
int templateLevel = 0;
|
int templateLevel = 0;
|
||||||
while(!syntaxer.eol()) {
|
while(!syntaxer.eol()) {
|
||||||
|
|
Loading…
Reference in New Issue