data: fixes for clearing on refresh
* reduce aggregation count when clearing * added TokenLocation to method override edge * added TokenLocations to template related edges
This commit is contained in:
@@ -37,12 +37,5 @@ ParseLocation::ParseLocation(
|
||||
|
||||
bool ParseLocation::isValid() const
|
||||
{
|
||||
if (startLineNumber == endLineNumber)
|
||||
{
|
||||
return startLineNumber > 0 && startColumnNumber <= endColumnNumber;
|
||||
}
|
||||
else
|
||||
{
|
||||
return startLineNumber > 0 && startLineNumber < endLineNumber;
|
||||
}
|
||||
return filePath.size() > 0;
|
||||
}
|
||||
|
||||
@@ -84,7 +84,8 @@ public:
|
||||
virtual Id onInheritanceParsed(
|
||||
const ParseLocation& location, const NameHierarchy& nameHierarchy,
|
||||
const NameHierarchy& baseNameHierarchy, AccessType access) = 0;
|
||||
virtual Id onMethodOverrideParsed(const ParseFunction& base, const ParseFunction& overrider) = 0;
|
||||
virtual Id onMethodOverrideParsed(
|
||||
const ParseLocation& location, const ParseFunction& base, const ParseFunction& overrider) = 0;
|
||||
virtual Id onCallParsed(
|
||||
const ParseLocation& location, const ParseFunction& caller, const ParseFunction& callee) = 0;
|
||||
virtual Id onCallParsed(
|
||||
|
||||
@@ -186,9 +186,10 @@ bool ASTVisitor::VisitCXXMethodDecl(clang::CXXMethodDecl* declaration)
|
||||
}
|
||||
|
||||
ParseFunction parseFunction = getParseFunction(declaration);
|
||||
ParseLocation location = getParseLocationForNamedDecl(declaration);
|
||||
|
||||
m_client->onMethodParsed(
|
||||
getParseLocationForNamedDecl(declaration),
|
||||
location,
|
||||
parseFunction,
|
||||
convertAccessType(declaration->getAccess()),
|
||||
abstraction,
|
||||
@@ -198,7 +199,7 @@ bool ASTVisitor::VisitCXXMethodDecl(clang::CXXMethodDecl* declaration)
|
||||
for (clang::CXXMethodDecl::method_iterator it = declaration->begin_overridden_methods();
|
||||
it != declaration->end_overridden_methods(); it++)
|
||||
{
|
||||
m_client->onMethodOverrideParsed(getParseFunction(*it), parseFunction);
|
||||
m_client->onMethodOverrideParsed(location, getParseFunction(*it), parseFunction);
|
||||
}
|
||||
|
||||
if (declaration->hasBody() && declaration->getBody() != NULL && declaration->isThisDeclarationADefinition())
|
||||
|
||||
Reference in New Issue
Block a user