Update the function's source location.

This commit is contained in:
Roberto Raggi
2010-08-13 13:47:39 +02:00
parent 497c5191e7
commit 1d30c09bd1

View File

@@ -1805,8 +1805,10 @@ bool Bind::visit(FunctionDefinitionAST *ast)
fun->setMethodKey(_methodKey);
}
if (declaratorId && declaratorId->name)
if (declaratorId && declaratorId->name) {
fun->setSourceLocation(declaratorId->name->firstToken(), translationUnit());
fun->setName(declaratorId->name->name);
}
_scope->addMember(fun);
} else