summaryrefslogtreecommitdiffstats
path: root/src/code.l
diff options
context:
space:
mode:
Diffstat (limited to 'src/code.l')
-rw-r--r--src/code.l14
1 files changed, 5 insertions, 9 deletions
diff --git a/src/code.l b/src/code.l
index 9428432..46de92c 100644
--- a/src/code.l
+++ b/src/code.l
@@ -276,7 +276,7 @@ void VariableContext::addVariable(const QCString &type,const QCString &name)
// otherwise look for global class definitions
(varType=getResolvedClass(g_currentDefinition,g_sourceFileDef,typeName,0,0,TRUE,TRUE))
) && // and it must be a template
- varType->templateArguments())
+ !varType->templateArguments().empty())
{
newDef = varType->getVariableInstance( templateArgs );
}
@@ -679,14 +679,10 @@ static void addUsingDirective(const char *name)
static void setParameterList(const MemberDef *md)
{
g_classScope = md->getClassDef() ? md->getClassDef()->name().data() : "";
- const ArgumentList *al = md->argumentList();
- if (al==0) return;
- ArgumentListIterator it(*al);
- const Argument *a;
- for (;(a=it.current());++it)
- {
- g_parmName = a->name.copy();
- g_parmType = a->type.copy();
+ for (const Argument &a : md->argumentList())
+ {
+ g_parmName = a.name;
+ g_parmType = a.type;
int i = g_parmType.find('*');
if (i!=-1) g_parmType = g_parmType.left(i);
i = g_parmType.find('&');